I use Sql Server compact database, and my linq query work properly in debug mode, but it has error in release mode ! My query use "join" and the exception is:
The method ' [My_Project_Namespace.MyTransactions,My_Project_Namespace.Users]. ' is not a property accessor
Here is my LINQ query:
var result = from transRow in db.MyTransactions
join userRow in db.Users on transRow.User_id equals userRow.Id
join clientRow in db.Clients on
transRow.Client_id equals clientRow.Id
select new
{
userId = transRow.User_id,
clientId = transRow.Client_id,
userName = userRow.Fname + " " + userRow.Lname,
clientName = clientRow.Fname + " " + clientRow.Lname,
reg_date = transRow.Reg_date,
value = transRow.Value
};
My aim is add (or replace) the user id with his name and also the client id with his name.