Questions tagged [multiple-resultsets]
103 questions
3
votes
1 answer
Why can't Postgres functions that return SETOF be called from a JDBC CallableStatement?
Is there a technical reason why a JDBC CallableStatement shouldn't be used to execute a PostgreSQL stored function that returns a SETOF (in particular REFCURSOR)?
Per the PostgreSQL JDBC documentation:
Functions that return data as a set should…

HamburglarHelper
- 31
- 2
3
votes
2 answers
Mybatis map multiple resultsets into object inner collections
Brief problem description
Following guideline for multiple resultsets and with help from this answer I now able to extract 2 different recordsets but they are just list and do not mapped on result object.
In details
I have classes…

Hubbitus
- 5,161
- 3
- 41
- 47
3
votes
3 answers
Using JPA with stored procedures that return multiple result sets
Is it possible to handle multiple result sets having different columns from a stored procedure in SQL Server using JPA? What is a way (or the best way) to do this?
I am currently working with Hibernate 4.3.5 Final and JPA 2.1, SqlServer 2008.
The…

laloumen
- 1,229
- 2
- 14
- 15
3
votes
1 answer
Hibernate JPA, inheritance and Stored Procedure returning multiple result sets
I am attempting to consume multiple result sets from a stored procedure using Hibernate 4.3.5.Final (JPA 2.1) -- and I have not been able to get it to work. I am using Sql Server 2008.
The stored proc result sets have different columns with some…

laloumen
- 1,229
- 2
- 14
- 15
3
votes
2 answers
phpMyAdmin hangs on proc with multiple SELECTS
When I CALL this proc in MySQL, it just shows LOADING... and even freezes my server:
delimiter $$
CREATE PROCEDURE MyProc(IN index1 INT, IN count1 INT, IN index2 INT, IN count2 INT)
BEGIN
SELECT id FROM view1 WHERE column1 IS NULL OR column1 = 1…
user1382306
3
votes
3 answers
SQL Server combine result sets
I'm trying to combine the result sets of two different queries into a single result set. Is this possible without using a stored procedure, perhaps using the WITH keyword?
Take the following case:
SELECT * FROM student WHERE graduation_year = 2013…

Adam Levitt
- 10,316
- 26
- 84
- 145
3
votes
1 answer
java ResultSet overwrite
I seem to be having some issues with my result sets I have named them differently but they both seem to have the same data in but I can't figure it out why.
String query = "SELECT * FROM blog_comments;";
ResultSet rs =…

bobthemac
- 1,172
- 6
- 26
- 59
3
votes
2 answers
How to prevent SQL from returning multiple resultsets
The issue I'm facing is that I have a stored procedure (lets call it sp_one), which during it's run calls another stored procedure (lets call it sp_two).
I'd only like the resultset from sp_one to be returned at the end, and not those from sp_two.…

Irfy
- 2,469
- 4
- 25
- 31
3
votes
1 answer
In Entity framework 4.0 how can we fetch multiple record set from database in one call & pass all data to View
In Entity framework 4.0 how can we fetch multiple record set from database in one call like we do in ado.net dataset?
Soppose we have 3 table T1,T2 and T3. We need to fetch data from all tree table and pass to view(ASP.NET MVC3). No JOIN is to be…

Paul
- 457
- 2
- 11
- 26
2
votes
6 answers
How can a function return a dynamic value that depends on the number of receivers in Python?
I was trying to do a "strange" (but useful in my case) function that can return a dynamic list whose len depends on the amount of receiver.
For example:
f() returns a dynamic list of None, so I can do the following:
a = f() => a = None
a, b = f() …

Xianbao QIAN
- 123
- 7
2
votes
1 answer
PostgreSQL: syntax error at or near "refcursor"
When I work with Microsoft SQL Server databases, I sometimes return multiple result sets from stored procedures. I often return so many that it becomes hard to follow which is which. To solve this problem, I follow a convention I learned from a…

kol
- 27,881
- 12
- 83
- 120
2
votes
1 answer
Read multiple result sets using query multiple
My procedure is returning two result sets/tables,
I want to read those two result sets into two different lists and bind that list.
I'm able to read one result set into a list but I tried various ways to read multiple result sets into the dynamic…

Shreyas Pednekar
- 1,285
- 5
- 31
- 53
2
votes
2 answers
How to populate many GridView controls from one stored procedure?
I have a stored procedure in SQL Server which returns seven result sets. I would like to call this stored procedure from ASP.NET and populate seven GridViews on my ASP.NET page with the results. I am using a SqlDataReader to get the data, however…

Mark Allison
- 6,838
- 33
- 102
- 151
2
votes
0 answers
Calling and handling stored procedures which returns multiple resultsets in Entity Framework
This is the department table which contains information about department
Dept_Id
Dept_Name
Dept_Desc
This is the employees table which contains information about employees.
Emp_Id
Emp_Name
Emp_Desc
Emp_Salary
Stored…

KMittal
- 602
- 1
- 7
- 21
2
votes
2 answers
PHP return self as array of objects from within the class?
I'm using CodeIgniter to build a php web application, and I'm trying to use good OO practices - of which there appears to be many schools of thought. I specifically have a class biography_model to interact with a MySQL table. This data model has…

WoMo
- 7,136
- 2
- 29
- 36