dbTalk Databases Forums  

Re: [BUGS] [PATCHES] insert into table (column) values (nullif('',''));

mailing.database.pgsql-bugs mailing.database.pgsql-bugs


Discuss Re: [BUGS] [PATCHES] insert into table (column) values (nullif('','')); in the mailing.database.pgsql-bugs forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
John Hansen
 
Posts: n/a

Default Re: [BUGS] [PATCHES] insert into table (column) values (nullif('','')); - 08-27-2005 , 12:36 AM






Since column is boolean, you need a boolean result:

insert into table (column) values (nullif(true,true));

Quote:
-----Original Message-----
From: pgsql-patches-owner (AT) postgresql (DOT) org=20
[mailtogsql-patches-owner (AT) postgresql (DOT) org] On Behalf Of Matt A.
Sent: Monday, August 22, 2005 3:22 AM
To: pgsql-bugs (AT) postgresql (DOT) org; pgsql-patches (AT) postgresql (DOT) org
Subject: [PATCHES] insert into table (column) values (nullif('',''));
=20
insert into table (column) values (nullif('',''));
ERROR: column "column" is of type boolean but expression is=20
of type text.
=20
inserting NULL works. nullif('','') should return NULL if=20
both values are equal? It works in MSSQL.
=20
Is there different function to accomplish a insert
nullif('','') test.=20
=20
Thanks
Matt
=20
=20
=20
=20
=20=09=09
__________________________________________________ __
Start your day with Yahoo! - make it your home page=20
http://www.yahoo.com/r/hs=20
=20=20
=20
---------------------------(end of=20
broadcast)---------------------------
TIP 4: Have you searched our list archives?
=20
http://archives.postgresql.org
=20
=20
---------------------------(end of broadcast)---------------------------
TIP 9: In versions below 8.0, the planner will ignore your desire to
choose an index scan if your joining column's datatypes do not
match


Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.