Replicación de DDL: MySQL
Obtenga información sobre la replicación de DDL en MySQL.
Limitación de la Replicación de DDL en MySQL
-
Caso 1: si DDL o
TRACKSCHEMACHANGESestán activados y la tabla está en la lista de captura. Extract finaliza de forma anormal con el siguiente error:DDL statement "CREATE TABLE AS SELECT" is detected for table '*table-name*' at binary log number '*binlog number*' and offset 'binlog offset'. The DDL operation "CREATE TABLE AS SELECT" is not supported. Execute all 'CREATE TABLE AS SELECT' DDL operations manually to the target database and start Extract by adding Extract parameter TRANLOGOPTIONS WARNCREATEASSELECT. Once Extract gets past the 'CREATE TABLE AS SELECT' operation, restart Extract after disabling the parameter TRANLOGOPTIONS WARNCREATEASSELECT.Debe realizar las acciones que se sugieren en el mensaje de error.
Cuando se utiliza el parámetro
TRANLOGOPTIONS WARNCREATEASSELECTen el archivo de parámetros Extract, Extract continúa después de emitir el siguiente mensaje de advertencia en el informe Extract, en caso de que se encuentre la operación'CREATE TABLE AS SELECT'posterior."DDL statement 'CREATE TABLE AS SELECT' is detected for table '*table-name*' at binary log number '*binlog number*' and offset '*binlog offset*'. The DDL operation 'CREATE TABLE AS SELECT' is not supported. The DDL and the associated DMLs are ignored." -
Caso 2: cuando la replicación de DDL o
TRACKSCHEMACHANGESestá desactivada y la tabla está en la lista Extract.When both DDL replication / TRACKSCHEMACHANGES are not enabled in the capture, the DDL and associated DML operations with CREATE TABLE AS SELECT are ignored. User needs to issue the same "CREATE TABLE AS SELECT" in the target as it was issued in the source.
Nota: Consulte TRANLOGOPTIONS WARNCREATEASSELECT en la Referencia de parámetros y funciones para Oracle GoldenGate para obtener más información.