Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Mailing Lists -> Oracle-L -> Re: date minus one
On Tue, 29 Mar 2005 12:55:06 -0600, Knight, Jon <jknight_at_concordefs.com> wrote:
> Just curious how the rest of the world gets "yesterday" in UNIX. We're
> running Solaris and we execute a sqlplus script with "select sysdate-1 from
> dual;" and pipe it to tail to set an environment variable.
>
> Is there a more UNIXy way, -or- maybe a java function. Any suggestions
> welcome.
>
> TIA,
> Jon Knight
I've done it in a shell script before, I don't remember exactly the commands but I do recall it was a lot more complex than it looks at first.
As I recall it's something like:
It's a lot of nested case statements.
Stephen
-- It's better to ask a silly question than to make a silly assumption. -- http://www.freelists.org/webpage/oracle-lReceived on Tue Mar 29 2005 - 14:15:08 CST
![]() |
![]() |