Thanks Ulrich.
I have made a query as given below:
SELECT DBNAME,
TBLNAME,
CAST(CREATTS AS DATE FORMAT 'YYYY-MM-DD')(CHAR(10))
AS CREATE_DATE
FROM DBC.TABLES
WHERE DBNAME = 'DB1'
AND TBLKIND = 'T'
AND CREATE_DATE >= ADD_MONTHS(DATE - EXTRACT(DAY FROM DATE) + 1, -1)
AND CREATE_DATE < (DATE - EXTRACT(DAY FROM DATE) + 1)
ORDER BY 3,2;
If I want to make the changes as per your suggestion, then how should this query look like?
Thanks
↧