Welcome Guest, Not a member yet? Register   Sign In
MYSQL Functions
#3

[eluser]vtafsar[/eluser]
Yes. I have already read active record class manual.
What I need is to run a query like:

UPDATE table_name SET field_name2=CONCAT(field_name2, "Some content") WHERE field_name1=1;

I tried the following code,

==================================================================
$this->db->where(field_name1, 1);
$this->db->update(table_name, array('field_name2'=> "CONCAT(field_name2, \"Some content\")"));
==================================================================

but it is not updating the field like what I am looking for.
Hope now you understand what is my question.

Thank You


Messages In This Thread
MYSQL Functions - by El Forum - 11-27-2009, 10:49 PM
MYSQL Functions - by El Forum - 11-28-2009, 01:58 PM
MYSQL Functions - by El Forum - 11-29-2009, 10:53 PM
MYSQL Functions - by El Forum - 11-30-2009, 05:48 AM



Theme © iAndrew 2016 - Forum software by © MyBB