Monday, October 17, 2016

Re: [google-cloud-sql-discuss] Anyway to disable only_full_group_by on 5.7

Is there a way to clear the sql mode (i.e, by making it an empty string)? Alternatively, how do you "unset"  a single flag via the gcloud tool?

On Saturday, October 1, 2016 at 12:22:57 PM UTC-4, Amit Marty wrote:
We added the sql_mode = TRADITIONAL to the mysql_flags section to get around this.



On Wednesday, August 3, 2016 at 12:26:51 PM UTC-5, David Newgas wrote:
By default Cloud SQL leaves the sql mode at the default, which includes strict_trans_tables in 5.7 but does not in 5.5 or 5.6.  So if you are running 5.5 or 5.6 it is already off by default.

If you are running 5.7 you can turn it off globally by setting the sql_mode flag to anything else, or blank. Because of the issue outlined earlier in this thread, this will remove some of the other modes too. The only way to remove just that one flag is to set the sql_mode session variable each time you connect as outlined earlier.

David

On Wed, Aug 3, 2016 at 10:19 AM, Hajar Homayouni <homayou...@gmail.com> wrote:
Hi,
How can I disable Strict mode in Cloud sql?


On Friday, June 3, 2016 at 10:34:35 AM UTC-6, David Newgas wrote:
Hi,

ONLY_FULL_GROUP_BY isn't actually a database flag, it is one of the possible parameters of the sql_mode database flag. sql_mode is one of the supported flags in Cloud SQL, which means you can change it by editing the instance properties. In order to remove ONLY_FULL_GROUP_BY but leave the other default modes you would need to set sql_mode to STRICT_TRANS_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE(etc). Unfortunately it seems that our validation only allows you to set one mode. This is a bug, which I am reporting now.

In the mean time the best workaround is to use SET SESSION sql_mode='...' at the start of each session to remove the mode.

David

On Fri, Jun 3, 2016 at 6:29 AM, Matt Bourne <matt...@gmail.com> wrote:
It seems like there is no super access and although you can add flags there appears no way to remove default flags like only_full_group_by

--
You received this message because you are subscribed to the Google Groups "Google Cloud SQL discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-cloud-sql-discuss+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-cloud-sql-discuss/b977f133-5127-4a54-9fa6-cdc7be6ac465%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "Google Cloud SQL discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-cloud-sql-discuss+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-cloud-sql-discuss/40ef3feb-bd42-4030-bf3c-f3475b2f9d95%40googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "Google Cloud SQL discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-cloud-sql-discuss+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-cloud-sql-discuss/346f1658-417a-4d1e-a8c7-acfe53506aac%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

1 comment:

  1. For the past two years using the sql_mode TRADITIONAL, set in the cloud console, worked perfectly. However that no longer appears to work and I am again seeing problems that make me think only_full_group_by is still active. I've tried setting
    in the connection script, to no avail :( I've tried setting it in the connection scripts also, though no luck.

    ReplyDelete