Toad World® Forums

Toad Formatter guide

Where can I find a guide or manual about the various Toad Formatter options?

I have several questions that don't have intuitive answers in the Oracle Formatter Options menu. For example:

  1. How do I define a replacement "default header", that a) is multi-line, and b) doesn't include the default "Formatted on mm/dd/yyyy hh::mi:ss (QP5 v5.374)" first line?

  2. How to get SELECT statements aligned (since SELECT is not DML, and there is no separate SELECT statement alignment category)?

  3. How to get these formatter options to be applied to auto-generated scripts (e.g., the "Script" tab on a table or view) without having to load the script into an editor and hit CTRL_SHIFT_F?

The Toad help has little-to-no useful information about the formatter (other than how to apply formatting to code in an editor or to files), and I cannot find any Toad formatter manual online.

Thank you.

Answering Q2:
Go to View -> Toad Options -> Formatter -> right tree -> Alignments - DML Statements

About Q1 (header): Entering multiple lines apparently requires explicit newlines ( \n ) to be coded to function, such as Hello\nWorld. Apparently no way to get rid of the "Formatted on..." message.


Disable the tagline option (Header node) if you don't want any descriptive comment after formatting.

Ah, I was speed-reading regarding your point about the formatting comment tag SwingCorey, sorry.
You want to replace the default tagline with your own version... I think Andre is correct... don't see a way to replace it totally with your own comment tag.

Thinking a little more about this, I created a "replace macro" that gets rid of the default tag line that Toad affixes to formatted code. I used a regular expression to find the QP5 formatter comment/s starting from the begin/comment chars.

So if you augment the tagline with your own header comments (via the Header node of the Formatter options tree) then after you format your code, you can use the regex-type replace per below. Hope this helps in the meantime. Wondering now if there's a way to shortcut it on the keyboard!??!


\(QP5 v5\.\d\d\d\) perhaps ?