The Author Online Book Forums are Moving

The Author Online Book Forums will soon redirect to Manning's liveBook and liveVideo. All book forum content will migrate to liveBook's discussion forum and all video forum content will migrate to liveVideo. Log in to liveBook or liveVideo with your Manning credentials to join the discussion!

Thank you for your engagement in the AoF over the years! We look forward to offering you a more enhanced forum experience.

pprasadravi (2) [Avatar] Offline
Hi ,
I am using Linq To SQL with stored procedures. When i check the return type is the stored procedure name.
My Table name is Customer and stored procedure name is SP_CIS_GetCustomers. The return type is SP_CIS_GetCustomers. Is there anyway ican get the return type is List<Customer>? Could you please help me on this?

Ravi Potturi
jwooley (123) [Avatar] Offline
Re: Linq To SQL Stored Procedure Return Type
You can set the return type by either dragging the stored proc onto the desired result type, or changing the "Return Type" in the designer. You can also manually create the stored procedure method as shown in chapter 8. Realze that there must be a direct mapping for all fields if you want the designer to allow the projection. With stored procedures, you can't change any of the field mappings (from Customer_Id to CustomerId for example) as you can with table mappings.