Celeb Glow
news | March 02, 2026

Running Oracle script from Notepad++

Can we configure Notepad++ to run an Oracle script? I mean, once we wrote some script (assume a PL/SQL script containing a procedure), can it be compiled from Notepad++ editor itself? If it is possible, what are the steps to do that?

2 Answers

Yes, just install a plugin called NppExec.

Steps:

  1. Open Notepad++
  2. Go to Plugins
  3. Select Plugin Manager
  4. Click on Show plugin manager
  5. Search the plugin called NppExec and install it
  6. Restart the Notepad++
  7. Write a query
  8. Press the key F6
  9. In the box write the next chain to connect:

--The following parameters in strong you will modify--

set ORA_USER=sys
set ORA_PASS=passforsys
set ORA_SID= MYINSTANCE

npp_save
cmd /c copy /y "$(CURRENT_DIRECTORY)\$(FILE_NAME)" "$(SYS.TEMP)\$(FILE_NAME)" >nul 2>&1
cmd /c echo. >> "$(SYS.TEMP)\$(FILE_NAME)"
cmd /c echo exit >> "$(SYS.TEMP)\$(FILE_NAME)"
sqlplus -l $(ORA_USER)/$(ORA_PASS)@$(ORA_SID) as sysdba @"$(SYS.TEMP)\$(FILE_NAME)"

  1. Clik on Save and name it for remember it.
  2. Clik on Ok to run the query
  3. Erase the "as sysdba" if you connect without superuser schema
  4. Enjoy

Regards!

Yes, you can create a Command in Notepad++, which can run any program, and you can get out the FULL_CURRENT_PATH to the currently open file, which you could send in as a parameter.

So all you'd need is a tool that will connect to an Oracle instance and execute a a file containing your sql script. Maybe you can do that with SQL*Plus, otherwise you can find tools on the net that'll let you do that, just search for something like tool to execute sql script oracle command line. Or it should be quite easy to write a tiny app that takes in a file containing a sql script and connects to the db and executes it.

0

Your Answer

Sign up or log in

Sign up using Google Sign up using Facebook Sign up using Email and Password

Post as a guest

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy