[Koha-bugs] [Bug 7785] MySQL-specific syntax in C4::Members columns()

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Wed Jul 10 02:13:16 CEST 2013


http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=7785

--- Comment #11 from M. Tompsett <mtompset at hotmail.com> ---
"LIMIT 1" is not ANSI SQL, though it does work for other SQL DBs, much more
than the SHOW COLUMNS that was there before. I only list "mysql," in my if
clause, because I figure those who wish to use a different back-end would also
seek to optimize things, and thus patch the if statement.

A specific non-"LIMIT 1" example is SQL Server, which uses TOP. Also, Oracle
seems to use some sort of rownum() logic.

So, there isn't a completely generic way of doing this in a quick fashion, but
by generalizing this further and using the db_scheme2dbi in C4::Context, I
believe this is a vast improvement.

-- 
You are receiving this mail because:
You are watching all bug changes.


More information about the Koha-bugs mailing list