I am facing an issue with creating data source for store procedure which is returning multiple table in response, not able to retrive all tables, currently I am getting only first table .
please suggest any method to solve this.
thanks in advance Jayesh Idnani
1 Answer, 1 is accepted
0
Momchil
Telerik team
answered on 07 Aug 2023, 07:15 AM
Hello Jayesh,
Indeed, the SqlDataSource component will only load the first result set if more than one is returned from the stored procedure (see Selecting Data with the SqlDataSource).
If dividing your existing stored procedure into separate ones for each result set is not an option, I can suggest the following workaround.
Use the ObjectDataSource component to read the data into a DataSet and set the DataSource and DataMember properties of the object data source accordingly (the DataMember property is the property you can use to indicate which table to bind to). Take a look at the Binding ObjectDataSource to a DataSet article for more information.