I was wondering what is the right way to use Stored Procedures with Linq to Sql. I mean the case when the SP is not fit to some DB table which is already an entity. For instance it computes something as MAX, or AVG and returns it's value via SELECT. Then it wont fit no entity and this means it would return an
This means that I can populate a DataRow with it but can't really use hard coded types which the SP returns.
Isn't there a way so that the Linq to SQL would make an entity based on the fields which the SP returns? It was possible with XSD datasets on previous versions (By just dragging the Proc to the XSD window). Can't this be done with Linq to SQL ?