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.
|
|
|
|
| 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 |
Send this thread to your friend |
|
|
|
|
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 Khokhar | 857 |
| Mohammed Taj | 746 |
| positive fanatic | 483 |
| Jayanta Sur | 479 |
| Vigyan Kaushik | 386 |
| Gopu Gopi | 335 |
| Gitesh Trivedi | 322 |
| Vinoth Kumar | 264 |
| neeraj sharma | 258 |
| Ramesh Jois | 246 |
|
|