Re: How to populate an LOV with SYSDATE, SYSDATE-1,etc.

From: Jurij Modic <jurij.modic_at_mf.sigov.mail.si>
Date: 1997/07/07
Message-ID: <33c0aa62.4840057_at_www.sigov.si>#1/1


On Mon, 7 Jul 1997 08:58:43 +0100, Mark Hide <mch_at_markhide.demon.co.uk> wrote:

>
>Could anyone tell me what SQL I need to generate a record group that
>will consist of the ten dates leading up to today ?
>
>Can I do it with a simple query or do I have to use PL/SQL ?
>
>Thanks.

SELECT TRUNC(sysdate) - rownum + 1
  FROM your_table
WHERE rownum <= 10;

Note that table your_table should have at least 10 records in it.

Regards,


Jurij Modic                             Republic of Slovenia
tel: +386 61 178 55 14                  Ministry of Finance
fax: +386 61  21 45 84                  Zupanciceva 3
e-mail: jurij.modic_at_mf.sigov.mail.si Ljubljana 1000
Received on Mon Jul 07 1997 - 00:00:00 CEST

Original text of this message