I need to convert this query from MsSql syntax to Oracle syntax:
select top 1 (convert(varchar, UPDATED_DATE, 23)) as date from DA_CATEGORY order by date desc
How do I do this? I need the data from both DB types to be the same string / value.
I need to convert this query from MsSql syntax to Oracle syntax:
select top 1 (convert(varchar, UPDATED_DATE, 23)) as date from DA_CATEGORY order by date desc
How do I do this? I need the data from both DB types to be the same string / value.
You can use the fetch
clause as follows:
select to_char(UPDATED_DATE,'YYYY-MM-DD') as date
from DA_CATEGORY
order by UPDATED_DATE desc
fetch first row only