In the procedure I want to set up to drop the partition in an hour. To prevent the procedure from falling, there will be no partitions, added IF EXISITS. But after starting the procedure, it displays an error ORA-00905 Missing keyword:
EXECUTE IMMEDIATE 'ALTER TABLE TEST_TABLE DROP IF EXISTS PARTITION FOR (TO_DATE(''' ||
TO_CHAR(trunc(sysdate, 'hh'),
'YYYY-MM-DD HH24:MI') ||
''', ''YYYY-MM-DD HH24:MI''))';