Format code keeps "recover datafile" lowercase

Hello,

Seem to remember that this has been posted before, but could not find anything relevant after a cursory search.

So, I recently got this following script snippet:

alter database datafile ‘dummy_file.dbf’ online;
recover datafile ‘dummy_file.dbf’;
alter database datafile ‘dummy_file.dbf’ online;
alter tablespace a_tablespace drop datafile ‘dummy_file.dbf’;

I copied it in SQLNav, selected it and did CTRL-R to format the code:

ALTER DATABASE DATAFILE ‘dummy_file.dbf’ ONLINE;
recover datafile ‘dummy_file.dbf’;
ALTER DATABASE DATAFILE ‘dummy_file.dbf’ ONLINE;
ALTER TABLESPACE a_tablespace DROP DATAFILE ‘dummy_file.dbf’;

The “recover datafile” statement stays lowercase…

On the other hand, when I just type in the statement, both words are uppercased as soon as I type “space” after each one (so it does recognize them as keywords then - preference “Keywords to Uppercase” is set).

Hi Dominique,

Thanks for reporting this. The formatter doesn’t recognize the “recover datafile” at all, but the code editor uses its own keywords repository so when you type in the words can be uppercased correctly. I have raised a CR for the formatter to fix this.

Thanks,
Vincent

Hi Dominique,

The formatter team explain that the “recover” is a SQLPlus command and the formatter doesn’t support SQLPlus keywords at the moment. The CR has been rejected. If one day we implement the formatting for SQL*Plus commands, I will let you know.

Thanks,
Vincent