Welcome Guest, Not a member yet? Register   Sign In
order by incorrect escaping
#1

[eluser]dmyers[/eluser]
My MySQL order by clause contains

$orderby = ‘concat(firstname,lastname) asc’

because I want to sort by the combined first and last names (which works in MySQL) but, when I try to add it with CI active record via $this->db->order_by($orderby) it doesn’t work because CI tries to escape it to ORDER BY CONCAT(firstname, `lastname)` asc which of course throws a MySQL error. How can I add it and not have CI try to escape it? Is there a secret “don’t escape” parameter?

I suppose a change as such needs to be done in the core files.


Messages In This Thread
order by incorrect escaping - by El Forum - 09-23-2009, 06:54 PM
order by incorrect escaping - by El Forum - 09-25-2009, 07:09 AM
order by incorrect escaping - by El Forum - 09-11-2013, 11:58 AM
order by incorrect escaping - by El Forum - 09-06-2014, 06:39 AM



Theme © iAndrew 2016 - Forum software by © MyBB