Re: Uses of Dual

From: Bill Reynolds <reynolds_at_silouette.com>
Date: 1996/08/21
Message-ID: <321BF280.993_at_silouette.com>#1/1


adizon_at_mail.us.net wrote:
>
> I know I can get the user's name by doing 'select user from dual' and I can
> also get the next sequence number with 'select seq.nextval form dual'. Are
> there any more uses of dual aside from these?
> Thanks.
>
> Lito Dizon
> adizon_at_us.net

Useful to "add" an extra value to a "picklist" that you do not always want to be a valid value.

If you create a view using the SQL:

select location_cd from location_tbl
union
select '*' from dual

you can then use the view instead of the table in situations where the list should include the "all locations" option defined by, in this case, an asterisk. Received on Wed Aug 21 1996 - 00:00:00 CEST

Original text of this message