Create classes against stored procedureshttp://forums.asp.net/t/1397383.aspx/1?Create+classes+against+stored+proceduresMon, 16 Mar 2009 16:48:18 -040013973833009735http://forums.asp.net/p/1397383/3009735.aspx/1?Create+classes+against+stored+proceduresCreate classes against stored procedures <p class="MsoNormal">Hi,</p> <p class="MsoNormal">In the TheeBeerHouse project if I created a stored procedure which comprises of 2 tables.</p> <p class="MsoNormal">For example </p> <p class="MsoNormal"><span style="color:blue">Create Procedure dbo.[EmpDept]</span></p> <p class="MsoNormal"><span style="color:blue">Select e.Name,e.Salary,d.Location,d.City</span></p> <p class="MsoNormal"><span style="color:blue">From Emp e, Dept d</span></p> <p class="MsoNormal">In the database we created stored procedure of every table like Get, Insert, Delete etc.<span style="">&nbsp; </span>And against each stored procedure we created funtion in .NET like Get(), Insert(Employee e), Delete(id) etc. </p> <p class="MsoNormal">My question is that if a stored procudre has 2 tables should I have to create another class for that procedure? Like for <b style=""><i style=""><span style="font-size:14pt; line-height:115%">EmpDept</span></i></b> procedure I have to create Detail class, Provider Class, Sqlclient provider class, and BLL class. Is this way is right? If yes it means if I have many procedures which comprises of different tables then I have to create classes again and again. </p> <p class="MsoNormal">Suggest me .</p> 2009-03-16T08:14:02-04:003010760http://forums.asp.net/p/1397383/3010760.aspx/1?Re+Create+classes+against+stored+proceduresRe: Create classes against stored procedures <p>&nbsp;You could use LINQ to SQL Classes</p> <a href="http://weblogs.asp.net/scottgu/archive/2006/08/27/Building-and-using-a-LINQ-for-SQL-Class-Library-with-ASP.NET-2.0.aspx" title="http://weblogs.asp.net/scottgu/archive/2006/08/27/Building-and-using-a-LINQ-for-SQL-Class-Library-with-ASP.NET-2.0.aspx">http://weblogs.asp.net/scottgu/archive/2006/08/27/Building-and-using-a-LINQ-for-SQL-Class-Library-with-ASP.NET-2.0.aspx</a> 2009-03-16T16:48:18-04:00