Re: empty string or null
- From: Andreas Mosmann <mosmann@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx>
- Date: Fri, 30 Mar 2007 09:25:28 +0200
Frank van Bortel schrieb am 29.03.2007 in <euh3bm$rhd$1@xxxxxxxxxxxxxxxxxxxxxxx>:
Andreas Mosmann schreef:
[snip]
try a JOIN ...Does this mean I have a job, and you don't?
SELECT * FROM ADDRESSES A
LEFT JOIN JOBS J ON
(A.FIRSTNAME=B.FIRSTNAME) and (A.MIDDLENAME=B.MIDDLENAME) and
(A.FAMILYNAME=B.FAMILIYNAME);
no MIDDLENAME- no job
Andreas Mosmann
:)
I know about VARCHAR2, so I would write the correct query ;)
SELECT * FROM ADDRESSES A
LEFT JOIN JOBS J ON
(A.FIRSTNAME=B.FIRSTNAME
or A.FIRSTNAME is NULL and B.FIRSTNAME is NULL)
and
(A.MIDDLENAME=B.MIDDLENAME
or A.MIDDLENAME is NULL and B.MIDDLENAME is NULL)
and
(A.FIRSTNAME=B.FAMILIYNAME
or A.FAMILIYNAME is NULL and B.FAMILIYNAME is NULL)
and NULL is NULL
and 1=1
and 2=2
..
and 'A'='A'
..
are you interested in knowing which job has Mr. ?
(long time ago he had to call himself "nobody", but now "" is a correct name)
best regards
Andreas <no middlename> Mosmann
--
wenn email, dann AndreasMosmann <bei> web <punkt> de
.
- References:
- empty string or null
- From: Tim B
- Re: empty string or null
- From: Frank van Bortel
- Re: empty string or null
- From: Andreas Mosmann
- Re: empty string or null
- From: Frank van Bortel
- empty string or null
- Prev by Date: oracle date in where clause
- Next by Date: Re: O9i: general index question
- Previous by thread: Re: empty string or null
- Next by thread: Getting last sequence number in c#
- Index(es):