Job Seekers   Employers
dbapool: Authors | Submissions | Contact Us
   Forgot password? | Sign up
  Home   Discussion Forum   Articles   Interview Questions   FAQs   Scripts   Rewards   Analyzer   White Papers   Blog   Certification   Downloads   Tools
 

Topic: Backup & Recovery >> Dynamic Procedure

Disclaimer: The purpose of all dbapool forums including OCP and Other Oracle Certification forums is to help each other with specific issues but not to share dump and copyrighted exam content, materials or intellectual property. You may review the entire Oracle Certification Program Candidate Agreement online Here.



  


 Title: Dynamic Procedure
 chinna  Posted: Oct 18, 2007 12:16:03 AM

 Total Post: 28
 Joined: May, 2007






 hi friends,

this procedure contains the dynamic creation of table and inserting data through a dynamic procedure.
when i compile it is giving no errors
but when i am executing it it is giving insufficent privileges.

CREATE OR REPLACE PROCEDURE EXECPROC
AS
VSQLSTMT VARCHAR2(4000);
BEGIN
EXECUTE IMMEDIATE 'CREATE TABLE SAMPLE1(VNO1 NUMBER,VNO2 NUMBER)';
VSQLSTMT := 'CREATE OR REPLACE PROCEDURE SAMPLE1
AS
BEGIN
INSERT INTO SAMPLE1 VALUES(12,''SRAWAN'');
INSERT INTO SAMPLE1 VALUES(26,''SKUMAR'');
END;';
EXECUTE IMMEDIATE VSQLSTMT;

END;

looking forward for reply....

Thanks & Regards
srawan

 suni
Posted: Oct 24, 2007 03:11:48 AM  

 Total Post: 11
 Joined: Oct, 2007






 


check whether the executing user has the EXECUTE privilege on that procedure.

 chinna
Posted: Oct 24, 2007 03:14:40 AM  

 Total Post: 28
 Joined: May, 2007






 
hi,
yes the user has privilege.

when i am executing in a anonymous block it is going fine...

thanks
srawan

 Time Zone: EDT

  




Forum Rules & Description


Who Can Read The Forum? Any registered user or guest
Who Can Post New Topics? Any registered user
Who Can Post Replies? Any registered user




 








Get FREE Magazines

Top 10 Forum User

  Murtuja Khokhar857
  Mohammed Taj746
  positive fanatic483
  Jayanta Sur479
  Vigyan Kaushik386
  Gopu Gopi335
  Gitesh Trivedi322
  Vinoth Kumar264
  neeraj sharma258
  Ramesh Jois246






oracle Mag



  About Us Advertise Terms of Use Privacy Newsletters Contact Us    

Home   Discussion Forum   FAQs  Articles  Jobs   Newsletters  Directory  Downloads 

Our Premium Sponsor
Confio Software