Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.server -> Re: Convert code from SQL Server 2000 to SQL Plus for Oracle
forbrich_at_telusplanet.net said...
> Karsten Farrell wrote:
>
> > It's been a while since I did TransactSQL, but I think your code can be
> > reduced to:
> >
> > select to_char(sysdate,'dd-Mon-yyyy'),
> > to_char(last_day(sysdate),'dd-Mon-yyyy')
> > from dual;
>
> So when did the (informal) policy change so that we actually provide
> answers? <g>
>
You *do* have a point there! Actually, I just remember how stunned I was
when I first encountered TransactSQL (though it was in Sybase) after
some ten years with Oracle ... got to where I hated those at-signs with
a passion ... very awkward for me to type. Was so glad when that company
(a dot-com) went belly-up and I could return to Oracle. But I might be
prejudiced. :)
However, if you try my solution, you'll see that I didn't really provide the answer. Hehe ... the first value should have been:
'01-' || to_char(sysdate,'Mon-yyyy')
but I didn't catch that when I was typing.
-- /Karsten DBA > retired > DBAReceived on Tue Apr 08 2003 - 14:59:55 CDT
![]() |
![]() |