[SQL] Functions with Null Arguments?

2000-08-14 Thread Thomas Swan
Is there anyway way to get the following to work? table foo id | name1   | name2 ---+-+--  0 | Abe | NULL  1 | William | Bill create function prefname(text, text) returns text as' declare name1 alias for $1; name2 alias for $2; begin if name2 isnull

RE: [SQL] select an entry with a NULL date field

2000-08-14 Thread Jesus Aneiros
I think undefined is the exact result for that comparison, therefore the returned error. False value will not be an error. -- Jesus Aneiros Sosa mailto:[EMAIL PROTECTED] http://jagua.cfg.sld.cu/~aneiros On Mon, 14 Aug 2000, Henry Lafleur wrote: > Comparing anything = NULL (if it would work) wou

[SQL] Creating A Rule to Increment a class size when a student adds that class to their schedule

2000-08-14 Thread Madel, Kurt
I am trying to create a rule that will increment the class.size in one table when a student adds that class to their schedule in another table (module). Basically, there are 3 tables involved: class module student When a student registers for their classes, the class.id is placed in its respecti

[SQL] copy from

2000-08-14 Thread Adam Lang
I need additional help involving the copy from command I have a database with several fields: id, name, address, zip id is the primary key and I use nextval to get a value. The file I want to upload is in comma separated value, that does not have a primry key (or an id) field. How would I use

Re: [SQL] select an entry with a NULL date field

2000-08-14 Thread Jesus Aneiros
Use select entry_id from tbl_date where date_02 is null; NULL = NULL is undefined according to SQL standards. -- Jesus Aneiros Sosa mailto:[EMAIL PROTECTED] http://jagua.cfg.sld.cu/~aneiros On Mon, 14 Aug 2000, Web Manager wrote: > ERROR: parser: parse error at or near "null" > >select entry

RE: [SQL] select an entry with a NULL date field

2000-08-14 Thread Henry Lafleur
Comparing anything = NULL (if it would work) would always false, at least that's how other servers treat it. You have to use IS NULL. select entry_id from tbl_date where date_02 IS NULL; Henry -Original Message- From: Web Manager [mailto:[EMAIL PROTECTED]] Sent: Monday, August 14, 2000

Re: [SQL] select an entry with a NULL date field

2000-08-14 Thread
Try select entry_id from tbl_date where date_02 is NULL; miguel sofer > >Hello, > > >I have a problem with PostgreSQL when I try to select or delete an entry >with an empty date. That's a typical entry > >Table tbl_date >- >entry_id154 >date_012000-01-15 >da

[SQL] select an entry with a NULL date field

2000-08-14 Thread Web Manager
Hello, I have a problem with PostgreSQL when I try to select or delete an entry with an empty date. That's a typical entry Table tbl_date - entry_id154 date_012000-01-15 date_02this date is NULL namemy_test - I want to

Re: [SQL] select an entry with a NULL date field

2000-08-14 Thread Mark Volpe
The syntax you're looking for is: SELECT entry_id FROM tbl_date WHERE date_02 IS NULL; Mark Web Manager wrote: > > Hello, > > I have a problem with PostgreSQL when I try to select or delete an entry > with an empty date. That's a typical entry > > Table tbl_date > ---

Re: [SQL] select an entry with a NULL date field

2000-08-14 Thread Kate Collins
Try: select entry_id from tbl_date where date02 is null; Kate Web Manager wrote: > Hello, > > I have a problem with PostgreSQL when I try to select or delete an entry > with an empty date. That's a typical entry > > Table tbl_date > - > entry_id154 > date_01