File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Oracle/OAS and the fly likes Execute Multiple SQL Queries in PL/SQL Procedure based on parameter Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Soft Skills this week in the Jobs Discussion forum!
JavaRanch » Java Forums » Products » Oracle/OAS
Bookmark "Execute Multiple SQL Queries in PL/SQL Procedure based on parameter" Watch "Execute Multiple SQL Queries in PL/SQL Procedure based on parameter" New topic
Author

Execute Multiple SQL Queries in PL/SQL Procedure based on parameter

Skanda Raman
Ranch Hand

Joined: Mar 21, 2008
Posts: 205


I have requirement to execute different sql queries using pl/sql procedure.



In my above proc if i pass PARAM as 1 i need to execute the first query and if PARAM is 2 the second query.

I am using OUT parameter as ref cursor, so that i want to display this results in JSP

However, on compiling this procedure, i am getting below error.



Please let me know where i am doing wrong. I am confused


Skanda
Skanda Raman
Ranch Hand

Joined: Mar 21, 2008
Posts: 205

Any Help On this..please
Agador Paloi
Ranch Hand

Joined: Jan 24, 2006
Posts: 118
try restructuring your code something like:

 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Execute Multiple SQL Queries in PL/SQL Procedure based on parameter