Yes, there is...The Editor window contains two functions that simplify copying SQL statements from Toad to code development tools such as Delphi, Visual Basic (VB), C++, Java, or Perl, and from those code development tools back to Toad. These functions are available from the Editor File toolbar or by using keyboard shortcuts.
Strip Code Statement
The Strip Code Statement function strips off the code development tool syntax from the SQL statement, ready to execute in Toad.
For example, if you take the following Visual Basic code from the Visual Basic development tool, copy it, paste it into Toad, and run Strip Code Statement, it changes the SQL statement from this:
Sql = " select count(*) as cnt"
Sql = Sql & " from all_tables"
Sql = Sql & " where owner = 'DEMO'"
Sql = Sql & " and table_name = 'EMPLOYEE'"
to this:
select count(*) as cnt
from all_tables
where owner = 'DEMO'
and table_name = 'EMPLOYEE'
Now the SQL is ready to execute in Toad.
If you have multiple SQL statements in the Editor, highlight the statement you want to strip before executing the Strip Code Statement function.
Make Code Statement
The Make Code Statement function adds the code development tool syntax to the SQL statement in the Editor and makes it ready to paste into the appropriate development tool.
When making code statements, rather than changing the code in the Editor window as the Strip Code Statement function does, the Make Code Statement function takes the currently highlighted SQL statement, translates it into the code development tool syntax, and copies it to the clipboard. You can now switch to the code development tool and paste in the results. A message displays in the status panel such as VB statement was copied to the clipboard.
See images below: