I have this tSQL query that is returning what I need to see from the data. I need this in linq method syntax to work as close as possible Ive been ...
I have this tSQL query that is returning what I need to see from the data. I need this in linq method syntax to work as close as possible Ive been ...
I'd like to get one list of IDs from all nested entities. Code: // Entities class Floor { public int Id { get; set; } public ICollection< ...
I have an one-to-many relation in my entities: I want to load Header and some of its Items, so I wrote this linq to entity query(EF6): This quer ...
I have a query which does a group by and then selects and then tries to apply a Where() filter on the select. but it throws error after I apply the fi ...
Someone can help me? How can I get all appsRelatedIds IN arrayList? I work on Api integration and I have the class Apps: I've created this LINQ and ...
I do have a "Tracking" table and "TrackingDetails" table. Tracking Table TrackingDetails Table [TrackingId is the foreign key of Tracking table's ...
I have a data like above and I want to get the data of only objects with label=1 from this data with the help of linq. In other words, 2 data shoul ...
I would like to remove repetitions in this paragraph of code. Is it possible to write a function to cleanup any table nvarchar columns with a specifie ...
I have a ReportStatusEntity class as shown below: Let's say I have the following list of List<ReportStatusEntity>(): I want to group by Po ...
I aways copy LINQtoSql query from code to LINQPad for testing, but it have a little inconvenient of this. My code: But when I copy it to LINQPad f ...
I am trying to select from a table where list contains a value using linq and entity framework. but its telling me it cannot create a constant and thr ...
Please consider these Tables: User: and Users Login Logs: No I want to find those users that don't login in specific duration (for example 1 pa ...
I have three tables, Chart, ChartQuestion, ChartAnswer A Chart has many ChartQuestions, a ChartQuestion has many ChartAnswers. I'd like to do a linq ...
I have 2 models: And The document categories are hierarchal and represented in the database like below: In the controller I have an action wh ...
I have a table now students has 3 Booleans checks The Booleans are not relevant to each other and doesn't depend on each other but the record sh ...
I'm trying to calculate the hours that fall during the week at a different rate than the ones worked during the weekend. This is how I was hoping to a ...
When I look for examples of LINQ statements, often the select result doesn't just return the object or properties directly but as a new anonymous type ...
I'm using EFCore and trying to get entities from the database sorted in DateTime order. The class looks like this, I googled and saw some other users ...
I am trying to allow support for querying on a date range in my get request. the "after" and "Between" work fine but I'd also like to implement "befor ...
I have two table like this : I want to create a report that shows howmuch balance has every customer. my linq query is : this query is ok in lin ...