I can not update when I use replication?

48 views
Skip to first unread message

Jonathan Diaz

unread,
Jan 19, 2018, 6:05:41 PM1/19/18
to Google Cloud SQL discuss

In the Cloud SQL documentation, specifically on this link, "https://cloud.google.com/sql/docs/mysql/features", mention the following:


unsupported statements for second generation instances

The following statements are not compatible because the second-generation instances use GTID replication:

statements CREATE TABLE ... SELECT CREATE TEMPORARY TABLE statements within transactions

Transactions or statements that update transactional and non-transactional tables


I often make updates to my data, so, that would be a problem for my solution.


In the google cloud documentation, in the same link mentioned above, it refers to the official documentation of mysql, which mentions that the restriction of updates are only with non-transactional engines.

Maybe I'm getting confused, but I really want to know if I can update my data or not. Sorry for the lousyness of English, it is obvious to say that I do not master it.

George (Cloud Platform Support)

unread,
Jan 19, 2018, 8:16:46 PM1/19/18
to Google Cloud SQL discuss
Hello Jonathan, 

The official MySQL documentation, at "17.1.3.4 Restrictions on Replication with GTIDs", says: 

"Updates involving nontransactional storage engines.  When using GTIDs, updates to tables using nontransactional storage engines such as MyISAM cannot be made in the same statement or transaction as updates to tables using transactional storage engines such as InnoDB.

This restriction is due to the fact that updates to tables that use a nontransactional storage engine mixed with updates to tables that use a transactional storage engine within the same transaction can result in multiple GTIDs being assigned to the same transaction. "

It is the mixed transactional and non-transactional table updates that are not supported, exactly what is stated on the page you linked: "Transactions or statements that update transactional and non-transactional tables". 



Jonathan Diaz

unread,
Jan 20, 2018, 12:28:44 PM1/20/18
to Google Cloud SQL discuss
IN SUMMARY, IF I ONLY HAVE TABLES WITH THE ENGINE INNODB, THIS PROBLEM DOES NOT EXIST?

George (Cloud Platform Support)

unread,
Jan 22, 2018, 10:21:48 PM1/22/18
to Google Cloud SQL discuss
You are right in saying so: the problem exists only for non-transactional mixed with transactional updates. Pure InnoDB is OK. Still, you need to take into consideration the global structure of the restrictions, as listed in the "Unsupported statements" paragraph linked above. 

Jonathan Diaz

unread,
Jan 23, 2018, 5:01:30 PM1/23/18
to Google Cloud SQL discuss
thank you very much george! Google Cloud is great!
Reply all
Reply to author
Forward
0 new messages