Home » SQL & PL/SQL » SQL & PL/SQL » sql script is not working in unix box
sql script is not working in unix box [message #289635] Mon, 24 December 2007 09:57 Go to next message
vickey_sagar1
Messages: 77
Registered: August 2007
Location: pune
Member

Hi,

Below sql script is not working properly. When i am calling
Sql script through $U schedule tool package procedure is executing fine but when i am calling directly procedure it is not executing
START $CFI_TOP/install/sql/password.sql
conn cme/&cme_pwd
BEGIN
   erp_util_pkg.set_context ('ERP_SWAP_SYNONYM_TO_RRL_OBJ');
   erp_util_pkg.begin_refresh ('ERP_SWAP_SYNONYM_TO_RRL_OBJ');

   EXECUTE 
   ERP_SWAP_SYNONYM_TO_RRL_OBJ('D'); -- statment is not working   

   erp_util_pkg.set_context ('ERP_SWAP_SYNONYM_TO_RRL_OBJ');
   erp_util_pkg.end_refresh ('ERP_SWAP_SYNONYM_TO_RRL_OBJ', 'C');

/*
   EXCEPTION
   WHEN OTHERS
   THEN
      DBMS_OUTPUT.PUT_LINE ('Exception : ' || 'SQLcode=' || SQLCODE);
      DBMS_OUTPUT.PUT_LINE (SQLERRM);
*/

END;
/

Please let us know what change require in this sql script.

Thanks in advance,
Sagar

[EDITED by LF: formatted the code to improve readability]

[Updated on: Tue, 25 December 2007 03:33] by Moderator

Report message to a moderator

Re: sql script is not working in unix box [message #289636 is a reply to message #289635] Mon, 24 December 2007 10:00 Go to previous messageGo to next message
BlackSwan
Messages: 25037
Registered: January 2009
Location: SoCal
Senior Member
>Below sql script is not working properly.
If you say so. I don't see any error or problem from here.

My car is not working.
Tell me how to make my car work.


Re: sql script is not working in unix box [message #289660 is a reply to message #289635] Tue, 25 December 2007 01:58 Go to previous messageGo to next message
Michel Cadot
Messages: 64110
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
EXECUTE is not part of PL/SQL, it is SQL*Plus statement.
See the previous and following lines you "wrote" to see how to call a procedure inside PL/SQL.

Regards
Michel
Re: sql script is not working in unix box [message #289662 is a reply to message #289660] Tue, 25 December 2007 02:19 Go to previous messageGo to next message
vickey_sagar1
Messages: 77
Registered: August 2007
Location: pune
Member

Thx for replay Michel!!

I tried to call procedure without EXECUTE statement in pl/sql but 'ERP_SWAP_SYNONYM_TO_RRL_OBJ' procedure is not executing. Please let me know what changes I need to made.

Thx,
Sagar
Re: sql script is not working in unix box [message #289663 is a reply to message #289662] Tue, 25 December 2007 02:23 Go to previous messageGo to next message
Michel Cadot
Messages: 64110
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
That's simple, fix the error.

Regards
Michel
Re: sql script is not working in unix box [message #289705 is a reply to message #289662] Tue, 25 December 2007 12:20 Go to previous message
S.Rajaram
Messages: 1027
Registered: October 2006
Location: United Kingdom
Senior Member
Hi vickey_sagar1,

If you change this to that, it should solve the problem.

Regards

Raj

[Updated on: Tue, 25 December 2007 12:20]

Report message to a moderator

Previous Topic: Display the error thrown by a SQL statement using a PLSQL trigger.
Next Topic: utl_file
Goto Forum:
  


Current Time: Mon Dec 05 10:45:40 CST 2016

Total time taken to generate the page: 0.18034 seconds