1

I want to source a sql file located in "C:\Users\Administrator\Desktop\malintha.sql" location. I used following command in sql plus

SQL> @C:\Users\Administrator\Desktop\malintha.sql

But it gives me

Unable to open file error.

How to do this correctly ?

1 Answer 1

2

You are doing it correctly but the file either isn't there or you have no permissions.

  1. Double check the path
  2. Ensure you are running the SQLPlus session in a command window with appropriate privs (perhaps Run As Administrator)
  3. Try executing from a regular user directory instead of Administrator

I just tested a SQL file with:

SQL> @C:\users\msmith\desktop\test.sql
Sign up to request clarification or add additional context in comments.

2 Comments

Path is correct but how to set priv for SQLPLUS session?
Open a new command prompt with "Run As Administrator", that is a Windows concept, not an Oracle concept. Right click the command prompt from the Start -> Programs menu, or type cmd into the "Start -> Run" omnibox and then right-click it to choose it.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.