My mistake. Some topics on this forum are not related to AllroundAutomations PL/SQL Developer (despite the fact that this forum is dedicated for that) and I figured that this one is one of those.
What I gave you is a method to pass SQL query from Windows command line do SQL*Plus application. As far as I know, there's no method of passing SQL or commands to it other than using standard input stream - there's no execution parameter of "sqlplus.exe" that could handle that.
What this means is that even if PL/SQL Developer had a Tools Configuration parameter to pass SQL from it's window to an external application (as far as I know it does not), you would have no way to use it with "sqlplus.exe" only - you'd have to use some dedicated application or script that would take SQL as an execution parameter, launch "sqlplus.exe" and pass the SQL on it's standard input stream.
The working (and much simpler) method is to use it as you did on the screen shot - pass path to an SQL file to "sqlplus.exe". What you could also do (and maybe already did) is to tick those options (on "Options" tab):
- "Save Window" (which would ensure that window content is saved to file before the file is passed to "sqlplus.exe"),
- "Active Connection" (which would make sure that there is user name, password and database to pass to "sqlplus.exe"),
- "Program Window", "SQL Window" and "Command Window" (to make sure that the tool is not available for "Test Window" and "Report Window" which produce a file that is not a valid SQL*Plus script file).
I'd also use "#dir" as "Default Path" (on "General" tab) to make sure that any SQL*Plus output spooled to files will not go to Oracle Client or PL/SQL Developer or system folders. And "#wconnect" as first execution parameter (in "Parameters" on "General" tab) instead of "#wusername/#wpassword@#wdatabase" as "#wconnect" would probably do proper escaping of special characters (as "/" in user name or "@" in password) which is not done in "#wusername", "#wpassword" and "#wdatabase".