|
Re: Not being able to Run procedure through Oracle SQL Developer 1.5 [message #349223 is a reply to message #349207] |
Fri, 19 September 2008 06:33 |
Olivia
Messages: 519 Registered: June 2008
|
Senior Member |
|
|
While trying to execute a procedure in Oracle SQL Developer I am getting the below code
DECLARE
P_PROFILE_ID NUMBER;
RC1 globalPkg.RCT1;
BEGIN
P_PROFILE_ID := NULL;
TEST_GRN_COUNT(
P_PROFILE_ID => P_PROFILE_ID,
RC1 => RC1
);
-- Modify the code to output the variable
-- DBMS_OUTPUT.PUT_LINE('RC1 = ' || RC1);
END;
I tried to run the query but showing no result.I am getting the below message in Running log but not being able to see the data.
Connecting to the database SXVNDB01.
Process exited.
Disconnecting from the database SXVNDB01.
|
|
|
Re: Not being able to Run procedure through Oracle SQL Developer 1.5 [message #349229 is a reply to message #349207] |
Fri, 19 September 2008 07:00 |
Olivia
Messages: 519 Registered: June 2008
|
Senior Member |
|
|
DECLARE
P_PROFILE_ID NUMBER;
RC1 globalPkg.RCT1;
BEGIN
P_PROFILE_ID := NULL;
TEST_GRN_COUNT(
P_PROFILE_ID => P_PROFILE_ID,
RC1 => RC1
);
-- Modify the code to output the variable
-- DBMS_OUTPUT.PUT_LINE('RC1 = ' || RC1);
END;
While trying to execute above query in Oracle SQL Developer I am getting error:
PLS-00306:wrong number or types of argument in call to PUT_LINE
I don't think it's a matter of displaying the cursor - a cursor is an abstract internal thing controlling the way that you access data. It's not something that can be displayed like a piece of text
How can I see the output data? Using bind variable I can see the data but Oracle SQL Developer is not accepting bind variable.
Thanks,
OLi
[Updated on: Fri, 19 September 2008 07:04] Report message to a moderator
|
|
|
Executing procedure in Oracle SQL Developer [message #349230 is a reply to message #349207] |
Fri, 19 September 2008 07:10 |
Olivia
Messages: 519 Registered: June 2008
|
Senior Member |
|
|
DECLARE
P_PROFILE_ID NUMBER;
RC1 globalPkg.RCT1;
BEGIN
P_PROFILE_ID := NULL;
TEST_GRN_COUNT(
P_PROFILE_ID => P_PROFILE_ID,
RC1 => RC1
);
-- Modify the code to output the variable
DBMS_OUTPUT.PUT_LINE('RC1 = ' || RC1);
END;
what need to be done to get the data for the above code
While trying to execute above query in Oracle SQL Developer I am getting error:
PLS-00306:wrong number or types of argument in call to PUT_LINE
I don't think it's a matter of displaying the cursor - a cursor is an abstract internal thing controlling the way that you access data. It's not something that can be displayed like a piece of text
How can I see the output data? Using bind variable I can see the data but Oracle SQL Developer is not accepting bind variable.
Thanks,
OLi
[Updated on: Fri, 19 September 2008 07:04]
|
|
|
Re: Executing procedure in Oracle SQL Developer [message #349231 is a reply to message #349230] |
Fri, 19 September 2008 07:12 |
JRowbottom
Messages: 5933 Registered: June 2006 Location: Sunny North Yorkshire, ho...
|
Senior Member |
|
|
In SQL*Plus, if you display a ref cursor in a bind variable, SQL*Plus will very nicely go off and fetch bakc all the data in that cursor, and print it for you.
In SQL Developer, you'll ned to write some code that isues Fetches against the cursor and then displays the values returned.
|
|
|
Re: Executing procedure in Oracle SQL Developer [message #349233 is a reply to message #349231] |
Fri, 19 September 2008 07:20 |
Olivia
Messages: 519 Registered: June 2008
|
Senior Member |
|
|
What modififications I have to make in the above mentioned code?
Have to use Fetch into..?
Here's the procedure:
create or replace PROCEDURE TEST_GRN_COUNTS
(
p_profile_id IN NUMBER DEFAULT NULL,
RC1 OUT globalPkg.RCT1)
is
begin
open RC1 for
SELECT PROFILE_ID FROM GRN_TBL
WHERE PROFILE_ID=_profile_id;
end;
Is there no way to execute by just passing the value and hance get the result?
Regards,
Oli
[Updated on: Fri, 19 September 2008 07:25] Report message to a moderator
|
|
|
|
Execute procedure in OSD [message #349242 is a reply to message #349207] |
Fri, 19 September 2008 08:05 |
Olivia
Messages: 519 Registered: June 2008
|
Senior Member |
|
|
Can't we execute a procedure that returns a recursor in Oracle SQL Developer by just passing the value without have to modify the code?
Regards,
Oli
|
|
|
|
Re: Execute procedure in OSD [message #349250 is a reply to message #349245] |
Fri, 19 September 2008 09:12 |
Olivia
Messages: 519 Registered: June 2008
|
Senior Member |
|
|
Michel Cadot wrote on Fri, 19 September 2008 08:25 | How many times will you post the same topic?
Regards
Michel
|
Quote: |
Can't we execute a procedure that returns a recursor in Oracle SQL Developer by just passing the value without have to modify the code?
|
expecting a response.
Regards,
Oli
|
|
|
|
|
Re: Execute procedure in OSD [message #349262 is a reply to message #349258] |
Fri, 19 September 2008 09:47 |
ThomasG
Messages: 3212 Registered: April 2005 Location: Heilbronn, Germany
|
Senior Member |
|
|
Can't we execute a procedure that returns a recursor in Oracle SQL Developer by just passing the value without have to modify the code?
No. Period.
Now stop YOUR irritation of most of the guys in this forum by repeatedly not complying with Posting Guidelines.
|
|
|