0

Am having difficulty getting both tables from a stored procedure. So far it only return the first table, my code is below:

seat_plan seatP = new seat_plan();
apiModel api = new apiModel();
try
{
    seatP.seats = new apiModel().Database.SqlQuery<seat_plan_seat>("EXEC LWP_SEAT_PLAN {0}", perf);
    seatP.labels = new apiModel().Database.SqlQuery<seat_plan_label>("EXEC LWP_SEAT_PLAN {0}", perf);
}
catch (Exception) { }

return seatP;

Any thoughts?

DavidG
  • 113,891
  • 12
  • 217
  • 223
HuwD
  • 1,800
  • 4
  • 27
  • 58

1 Answers1

0

You could try storing the results of your stored procedure into a DataSet object and then pulling data from the various tables following the example:

queryResultsDataSet.Tables[tableIndex].Rows[rowIndex][columnName]
Stunan
  • 46
  • 3