Search Results

Search found 1 results on 1 pages for 'user1651446'.

Page 1/1 | 1 

  • Oracle SQL outer join query puzzle

    - by user1651446
    So I am dumb and I have this: select whatever from bank_accs b1, bank_accs b2, table3 t3 where t3.bank_acc_id = t1.bank_acc_id and b2.bank_acc_number = b1.bank_acc_number and b2.currency_code(+) = t3.buy_currency and trunc(sysdate) between nvl(b2.start_date, trunc(sysdate)) and nvl(b2.end_date, trunc(sysdate)); My problem is with the date (actuality) check on b2. Now, I need to return a row for each t3xb1 (t3 = ~10 tables joined, of course), even if there are ONLY INVALID records (date-wise) in b2. How do I outer-join this bit properly? Can't use ANSI joins, must do in a single flat query. Thanks.

    Read the article

1