"Darren Duncan" wrote...

On 2014-09-01, 6:50 PM, jose isaias cabrera wrote:
Thanks for this, but how do I set a value to null?

insert into foo (myfield) values (null);

That's one way. If you're using some wrapper API, then the host language's analagy of an undefined value, eg undef in Perl, should do it.

I thought null and '' were
the same, but now I see it is not.

Have you used Oracle before?

Written a few lines here and there, but, that is not where I got it from, though. And I agree, NULL and '' is not the same.


Oracle treats NULL and '' as the same, but that's a problem with Oracle which gives its users no end of headaches.

The SQL standard and basically every other SQL DBMS treats NULL as being distinct from every other value, which is how it is supposed to be.

-- Darren Duncan

_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to