Questions tagged [multiple-resultsets]
103 questions
0
votes
4 answers
How to return 2 ResultSet?
Hi I am trying to fetch data from 2 place.
One from Database and second from class file.
After getting data I want to return those both ResultSet object to other file using return keyword but how to return 2 resultsets I don't know.
My code :
public…

Java Curious ღ
- 3,622
- 8
- 39
- 63
0
votes
1 answer
Java StoredProcedure with SqlReturnResultSet not working
I have this SP in my Dao class:
private class ScoreStoredProcedure extends StoredProcedure {
private static final String SPROC_NAME = "loadUserScore";
public ScoreStoredProcedure(DataSource datasource) {
super(datasource,…

nano_nano
- 12,351
- 8
- 55
- 83
0
votes
1 answer
HDBC and multiple resultsets in a single statement: only first resultset returned
I'm looking for a way for HDBC to support multiple resultsets in a single statement
testMultipleResultsetSingleStatement = do
let sql = "select 1,2,3 union all select 2,3,4 select 'a', 'b'"
c <- connectODBC connectionString
rs <- quickQuery c…

smoothdeveloper
- 1,972
- 18
- 19
0
votes
0 answers
Stored Procedure returning more than 1 result set
I have read that a stored proc can return more than 1 result set.
Lie it can be defined as below.
CREATE PROC Sales.ListSampleResultsSets
AS
BEGIN
SELECT TOP (1) productid, productname, supplierid,
categoryid, unitprice, discontinued
FROM…

TheWommies
- 4,922
- 11
- 61
- 79
0
votes
1 answer
What order are result sets returned when using JDBC callable stmt to stored proc?
(1) When you open multiple cursors in a stored procedure, and then use a JDBC callable statement to iterate through the result sets, each in turn, are the order in which they are returned the same order in which they cursors are opened in the stored…

David Neuschulz
- 959
- 1
- 8
- 14
0
votes
2 answers
Java thread on resultset oracle
I am new to java. I am trying to create program to throw value to ResultSet in different thread.
ResultSet rset = stmt
.executeQuery("select DISTINCT substr(file_type,1,3) from DBM.file_table where process_time= '0015' ");
while…

Seth
- 15
- 2
- 5
0
votes
2 answers
Retrieving the number of results sets from a Sql server stored procedure from c#
Hi I am writing a T4 template to generate accessors for Sql server stored procedures. I have used a mixture of SMO and DeriveParameters method of CommandBuilder to get almost all of the information I need.
I am however unable to find a way of…

user1636171
- 1
- 1
0
votes
0 answers
Is it a good idea to have a single stored procedure to return multiple result sets?
If not, is there any work-around if we still want all the information to come from the same stored proc? Like wrapping these result-sets in something else(?). I have a stored proc that returns multiple result sets and it works fine. However, testing…

neuDev33
- 1,573
- 7
- 41
- 54
-1
votes
2 answers
How to use Resultset rs.next() multiple times in a single jdbc class using java jdbc?
I have a database with two fields orderid,flow.
Orderid field will be having n number of orderid integers.
flow field will be having 7 strings ,to categorize the order id belongs to this flow.
Now i want to categorize all the orderid fields…

Ilavarasan Jayaraman
- 293
- 1
- 6
- 25
-1
votes
1 answer
JDBC: How to clear the contents of a result set before using it again?
I want to clear the contents of a result set (but nothing should happen to the underlying database) before using it again to execute a new query?
Is there any method which will delete its data (but do nothing to the underlying database, that's…

Solace
- 8,612
- 22
- 95
- 183
-1
votes
1 answer
get table name of resultset Mysql
I am using PHP PDO. My stored procedure returns two result sets. Is it possible to name the result sets? In case they are SELECT statements on two tables like,
SELECT * FROM A
and
SELECT * FROM B
Is it possible to identify them?

7HUND3RX
- 175
- 3
- 14
-2
votes
2 answers
Resultset automatically close itself and showing error Operation not allowed after ResultSet closed
Getting Exception
java.sql.SQLException: Operation not allowed after ResultSet closed
<%
ResultSet rs=null,rs1=null;
Statement stmt=null,stmt1=null;
String UserID = request.getParameter("UserID");
String Password =…

cbsecommerce
- 47
- 1
- 6
-3
votes
1 answer
Java JDBC Single Statement object before while loop and inside while loop
I am writing one core java program with JDBC to connect to Oracle.
I am selecting my First table with a select condition to get few row ids. I got some records selected in the resultset
Now I am looping the resultset in a while loop (while…

Manohar Amkem
- 35
- 5