Hi Rob, Brian
On 20/08/2008, at 2:38 PM, Rob Wultsch wrote:
On Tue, Aug 19, 2008 at 9:25 PM, Brian Aker <[EMAIL PROTECTED]> wrote:
I am cleaning out the last of the modes.
What is the skinny on ONLY_FULL_GROUP_BY? This is a compatibility
question vs the standard.
Cheers,
-Brian
For whatever it's worth I think it would be missed if
ONLY_FULL_GROUP_BY was permanently set on or not configurable. Many
MySQL users are like a fish out of water when they start getting
errors from GROUP BY queries that other MySQL environments do not
find objectionable. Some very smart people find the setting too
restrictive:
http://www.oreillynet.com/databases/blog/2007/05/debunking_group_by_myths.html
Let's simplify.
The MySQL bug is described here: http://bugs.mysql.com/bug.php?id=8510
Essentially, the ONLY_FULL_GROUP_BY setting also rejects constructs
that it should allow:
create table foo (a int, b int);
insert into foo values (1, 2), (1, 3), (null, null);
select sum(a), count(*) from foo group by a; -- This one works
select round(sum(a)), count(*) from foo group by a; -- This fails
select ifnull(a, 'xyz') from foo group by a; -- This fails
I would be in favour of fixing this actual problem and then forcing
only_full_group_by (getting rid of sql_mode).
Regards,
Arjen.
--
Arjen Lentz, Founder @ Open Query
Training and Expertise for MySQL in Australia and New Zealand
http://openquery.com.au/training/ (ph. +61-7-3103 0809)
_______________________________________________
Mailing list: https://launchpad.net/~drizzle-discuss
Post to : [email protected]
Unsubscribe : https://launchpad.net/~drizzle-discuss
More help : https://help.launchpad.net/ListHelp