“Yawn!”, did I hear you say?
Well, it isn’t going to set the world on fire, but in SQL*Plus and SQLcl you can use scripts to set up some things that may be useful at the prompt.
Highlight when you’re logged in as SYS on a production server, have the prompt show which database on which server you’re logged into and know your session ID and serial# without needing to look it up.
If you execute a script in login.sql in SQLcl, the following is the response:
login.sql found in the CWD. DB access is restricted for login.sql. Adjust the SQLPATH to include the path to enable full functionality
As of Oracle 12.2 this would not execute automatically.
To allow execution in 12.2 set the SQLPATH.
Of course you can customise the script with the colours that suit your purpose.
The scripts can be fetched from:
git clone https://github.com/johnthomas22/SQLUtils.git
If you find this useful, please let me know.