views:

39

answers:

1

We are using Linq-to-SQL with stored Procedures we need help on one of our problem. We are having user tables which is having all field required for user table like firstname,lastname and other fields that table is also there in our DBML files.Now the problem is that we are having a stored procedure that is mapped to table->User returning a field called fullname (Combination of firstname and lastname)which is not there in usertable. So what is the best way to slove this.

Another thing is that one of other stored procedure return inner join of two tables with mix columns in this case how can i mapped that stored procedure with Table mapped info class in our dbml files.

A: 

We recommend you to use a computed property defined in the partial class. It will not be influenced by code regeneration in case any changes are made to the model.
For the table with mixed columns one of possible solutions is to create a view in the database with a structure identical to the set of mixed columns.

Devart