Trying to order by as follows:
SELECT DISTINCT TO_DATE(e.PUB_DATE_PRINT, 'DD Mon YYYY') AS "Publication Date"
FROM TABLE
ORDER BY e.PUB_DATE_PRINT DESC
I'm getting an error here because of the date, as there are some nulls in my e.PUB_DATE_PRINT column.
I can't seem to work this out...! Any help would be greatly appreciated.
Order by
is the last clause in the query to be applied, so it already has the final resultset to work on.
Is this what you want?
SELECT DISTINCT TO_DATE(e.PUB_DATE_PRINT, 'DD Mon YYYY') AS "Publication Date"
FROM TABLE
ORDER BY 1
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.