Click here to Skip to main content
15,881,092 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more: , +
Hi,
I am new to ADO.NET Entity Model,I need to fetch data from more than 2 tables using store procedure + function import method or any other type,
I am currently using function import + SP to fetch the data from only one table.
Please help me in this

Thank you in advance
Posted
Comments
Nandakishore G N 22-Oct-13 6:51am    
if you are using single table use entity object and if multiple tables use complex object
ravithejag 22-Oct-13 7:55am    
Thank u
Nandakishore G N 22-Oct-13 7:59am    
if it is concluded.Please , close the question by changing status solved.
So that others can get help from this question.

C#
con = new SqlConnection();
con.ConnectionString = ConfigurationManager.ConnectionStrings["StudentConnectionStr"].ConnectionString;
con.Open();
DataSet ds = new DataSet();
SqlParameter sp=new SqlParameter("@sid",value);
ds = SqlHelper.ExecuteDataset(con, CommandType.StoredProcedure, "Getstudentdetail", sp);
dt = ds.Tables[0];
 
Share this answer
 
v2
By using complex object i am able to fetch the data from more than 2 tables
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900