Hi
Dataset is used to hold the multiple tables. if we have to store multiple table on it, we can do like this
Declare the dataset as global
DataSet ds = new DataSet();
public DataSet fill()
{
//First table
SqlCommand cmd = new SqlCommand(“Select EmpName from tblEmp”, con);
SqlDataAdapter da = new SqlDataAdapter(cmd);
da.Fill(ds.Tables.Add());
ds.Tables[0].TableName = “Test”;
//Second table
SqlCommand cmd1 = new SqlCommand(“Select EmpName from tblEmp1”, con);
SqlDataAdapter da1 = new SqlDataAdapter(cmd1);
da1.Fill(ds.Tables.Add());
ds.Tables[1].TableName = “Test1”;
return ds;
}