Reputation: 4886
How does Slick handle a query that returns multiple result sets?
For example, if I wanted to retrieve information about a table using sp_help someTableName
Which would return a number of result sets. I can get the first result set, simply using scala.slick.jdbc.StaticQuery.queryNA[Tuple4[String, String, String,String]]("sp_help tblInbox_membership").first()
How do I get the second result set?
Upvotes: 1
Views: 914
Reputation: 1905
You must be using Sybase or maybe SqlServer.
I'm not familiar with Slick (yet), but the way to access subsequent ResultSet
s from a statement in JDBC is to call Statement.getMoreResults()
, then if that succeeds Statement.getResultSet()
. Slick gives you a Statement object with Session.withStatement
, so you could at least use the JDBC api to get your resultsets, or feed the ResultSet to Slick if there is a way to do that.
Upvotes: 1