REGEXP_SUBSTR extends the functionality of the SUBSTR function by letting you search a string for a regular expression pattern. It is also similar to REGEXP_INSTR, but instead of returning the ...
SELECT TO_DATE('{RUN_DATE_YYYY/MM/DD}', 'YYYY/MM/DD') - (TO_NUMBER(TO_CHAR(TO_DATE('{RUN_DATE_YYYY/MM/DD}', 'YYYY/MM/DD'),'DD')) - 1) AS Snapshot_Day ,ASIN ,Order_ID ...