‎2008 Apr 03 10:04 PM
Hi,
I have 2 table. in that I need to do join. But 2 fields of table A that I need to join with the 2 fields in table B.
But problem is that both the fields of table A can be NULL(either of them).
i.c.
Table A Table B
-
-
KONDA KUNNR PRICESHEET KONDA KUNNR
-
-
KA NULL A KA 1000
KA NULL B KA 1001
DZ NULL C DZ 1002
NULL 1000 D DZ 1003
NULL 1001 E DZ 1004
NULL 1002 F
NULL 1003 F
NULL 1004 G
After Joining I need for KONDA = 'KA'
-
KONDA KUNNR PRICESHEET
-
KA NULL A
KA NULL B
NULL 1000 D
NULL 1001 E
Could you plz help me...Plz reply soon. Thanks in advance
Regards
Anutosh
‎2008 Apr 03 10:47 PM
select a~konda a~kunnr a~pricesheet from table_a as a
join table_b as b on ( a~konda = b~konda or a~konda eq space ) and (a~kunnr = b~kunnr or a~kunnr eq space )
where b~konda = 'KA'.
Try that
Edited by: Ramiro Escamilla on Apr 3, 2008 11:48 PM
‎2008 Apr 03 10:47 PM
select a~konda a~kunnr a~pricesheet from table_a as a
join table_b as b on ( a~konda = b~konda or a~konda eq space ) and (a~kunnr = b~kunnr or a~kunnr eq space )
where b~konda = 'KA'.
Try that
Edited by: Ramiro Escamilla on Apr 3, 2008 11:48 PM