Sometimes you need to use a different COLLATE, to do a select for example, and be case sensitive or accent sensitive.
At the moment this is not possible using the query builder unless you write you own plain sql query.
I think it would be a good idea to add a method like collate() or something generic like additional() (or something like that) that allow to attach non standard statements like COLLATE to the generated query.
I hope I have been clear enough explaining the case.
Page 1 of 1
Add optional statements to SQL builder like COLLATE
#2
Posted 08 December 2011 - 11:27 AM
Can you check how to achieve that for MySQL, SQLite, PostgreSQL, MSSQL and Oracle?
#3
Posted 09 December 2011 - 05:19 AM
samdark, on 08 December 2011 - 11:27 AM, said:
Can you check how to achieve that for MySQL, SQLite, PostgreSQL, MSSQL and Oracle?
From a simple google search, this is what I have found:
MySQL http://dev.mysql.com...et-collate.html
MSSQL http://msdn.microsof...y/ms184391.aspx
SQLite http://www.sqlite.or....html#collation
PgSQL http://www.postgresq.../collation.html
Oracle http://docs.oracle.c...v.htm#sthref362
#4
Posted 28 December 2012 - 10:59 AM
zekus, on 08 December 2011 - 06:26 AM, said:
or something generic like additional() (or something like that) that allow to attach non standard statements like COLLATE to the generated query
Or different sorting options like
SORT BY row DESC NULLS LASTfor example.
I think that would be quite useful.
#5
Posted 01 January 2013 - 02:39 PM
Can't you already add these things with CDbCriteria methods? And the sort by nulls last using a CSort?
Share this topic:
Page 1 of 1

Help
This topic is locked










