Re: Query & Column Display

From: Ed Prochak <>
Date: Thu, 22 Jan 2009 09:51:57 -0800 (PST)
Message-ID: <>

On Jan 22, 12:12 pm, wrote:
> I did this once before a long time ago, but cannot remember how.
> Say I have 2 tables.  I query table #1, and if the value I am looking
> for is not there, then get the value from table 2.
> Both tables have the same primary key, so they must be joined.  I
> remember this was NOT a lot of code with subselects and all that
> jazz.  But I cannot recall how it was done.
> Was looking at analytical stuff for this, but no luck yet......
> Thanks!

NVL() ?? select nvl(table1.val, table2.val) valueLookingFor from table1, table2
where table1.key = table2.key.

  Ed Received on Thu Jan 22 2009 - 11:51:57 CST

Original text of this message