Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

FSharp.Data.SqlClient with multiple result sets

With FSharp.Data.SqlClient, how do you use SqlCommandProvider or SqlProgrammabilityProvider with multiple result sets? For instance if you wanted to get Customer+Orders where your stored procedure returns the customer info in the first result set and the orders in the second result set?

records:

{ OrderId=4; Date=xxx }
{ Name="Dave Smith"; Orders=[...] }

sp:

   Select Name From Customer Where CustomerId=@CustomerId
   Select OrderId, Date From Orders Where CustomerId=@CustomerId
like image 583
schmoopy Avatar asked Apr 20 '26 23:04

schmoopy


1 Answers

FSharp.Data.SqlClient is based on sys.sp_describe_first_result_set. As such, it ignores second result set completely.

like image 181
Dmitry Sevastianov Avatar answered Apr 23 '26 19:04

Dmitry Sevastianov



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!