Closed ingezone closed 3 years ago
Probably join with Table1 is not needed. I have left that because it was your original query.
join t1 in table1.Where(x => x.device == "ZZ300") on new { t2.CoordX, t2.CoordY } equals new { t1.CoordX, t1.CoordY }
The union is necessary because I perform a filter for each device that is in table 1.
I forgot to comment what I am trying to do now, with this last code I need to implement a query that returns me a range of months from 01 to 12, if any month does not exist in table 2, the value field of the missing month must be filled with a null value.
`var rawData = query.ToLinqToDB();
The 'rawData' variable is correctly delivering the data, but when passing through the 'enrichedData' variable it only returns null values. `
So examine why left join is not working, Probably returned data has time and it needs to be truncated.
You were absolutely right, I made the change and it works correctly,
Thank you........... :👍
Your code works perfect!!! Thank you very much...
Using your code as a guide, I did the following but I get only null values, I can't find the error.
The result of my query should be:
My code snippet: