Welcome Guest, Not a member yet? Register   Sign In
Active record and NULL value ?
#1

[eluser]ariok[/eluser]
Hi all,
I found this problem working with active record:
What i have to do if i need to insert a NULL value in my DB ?

if i have array data with:
"fieldone"=>"this value",
"fieldtwo"=>null

the query generated with $this->db->insert($array)... is something like:

Code:
(fieldone,fieldtwo) values ("this value",[b]"null"[/b])

But i want a query like

Code:
(fieldone,fieldtwo) values ("this value",[b]null[/b])

with null and not "null"....

there's a pratical way to obtain the second query instead first?

Thank you all ..

Ariok


Messages In This Thread
Active record and NULL value ? - by El Forum - 12-21-2007, 05:10 PM
Active record and NULL value ? - by El Forum - 12-21-2007, 07:34 PM
Active record and NULL value ? - by El Forum - 12-22-2007, 04:39 AM



Theme © iAndrew 2016 - Forum software by © MyBB