Skip to main content

All Questions

Tagged with
0 votes
1 answer
46 views

Fetch the Name based diff version for same Service and Function

Here is my Json object . [ { "Id": 1, "Name": "Asset A", "Version": 1, "Function": "Song", "Service": "Song" ...
Pinky's user avatar
  • 59
0 votes
0 answers
32 views

Asp.net mvc devextreme datagrids - How do I load 3 list items from 1 query without breaking column sorting and ordering

The following is what I'm trying to do, but breaks columns sorting and ordering In the controller var records = _service.GetRecords().Select(s => new { RecordId = ..., ... ...
Neoharry's user avatar
0 votes
2 answers
48 views

Linq query filtering null values last in asp net core mvc

I have a table in db name Guest as follows: Guest1 Guest2 Guest3 Guest4 James Tom Jerry Steve Jones Chris Luke Pet Ron Rob James I want the desirable table below such that ...
Jeff's user avatar
  • 125
0 votes
0 answers
45 views

LINQ join 2 tables having a DateTimeOffset foreign key

How can I join 2 tables when they are sharing a foreign composite key in the data type DateTiimeOffset? Please, refer to the following query. from o in outstandingOrders join d in ...
Lakshitha Kanchana's user avatar
0 votes
2 answers
248 views

Unable to cast object of type 'System.TimeSpan' to type 'System.DateTime'. Error while trying to get data from SQL Server

I'm currently working on a project that uses SQL Server. And I'm trying to get data from the Randevular table. But when I run the linq code, it doesn't return any data. I get an error Unable to cast ...
Mhanzo's user avatar
  • 1
0 votes
2 answers
69 views

Improving performance (IEnumerable vs IQueryable) in my project

I am using Telerik in ASP.NET MVC to display a grid that houses result data. We have a database of nearly 400k records, so I need to be sure my queries are performance friendly as possible. I have the ...
Eli's user avatar
  • 549
1 vote
1 answer
65 views

How can i make my Query faster using a Groupby with LINQ

I created a Query, it is pretty fast but my table will have 100k+ or even a 1 million records. With 100k rows it takes 5s to load and that is to long. I know using First() is also querying, but I can'...
TwanCS's user avatar
  • 11
0 votes
2 answers
167 views

How to Loop through IEnumerable List and if there are any duplicates, sum a value each duplicate has and remove the duplicates in ASP.Net MVC C#

I have an inventory usage page that is populated with a list of items I've used over the course of a certain period of time (like a month or so). There's a good amount of items that are duplicates and ...
Kip M.'s user avatar
  • 57
2 votes
0 answers
76 views

Multiple Joins with LINQ

I have this query: public IQueryable<PostView> PostJoinQuery() { return _context.Posts.GroupJoin( _context.Users, post => post.User_Id, ...
Martín Cárdenas's user avatar
0 votes
1 answer
314 views

LinqToDB.LinqToDBException error in group by linq query in nopcommerce

Here is my group by query var query = ( from fee in _walletRepository.Table group fee by fee.PartyId into groupResult select new { partyId = groupResult.Select(x => x....
s.k.Soni's user avatar
  • 1,220
0 votes
0 answers
29 views

I'm gettin error about something call "Lambda"

@foreach (var item in Model.ozellikler) { if (item.ozellikAtama != null && item.ozellikAtama == 0) { \<h3\>@item.ozellikAdi\</h3\> var ...
Michael Mandacı's user avatar
0 votes
2 answers
209 views

Linq Query taking too long to load

I have the following linq query - IQueryable<VaccinationClinic> clinics = _appDbContext.VaccinationClinics .Include(h => h.HealthBoard) .Include(c => c....
user20408154's user avatar
1 vote
1 answer
55 views

Inner Join in Linq Method

I have a query var casino = await _context.Casinos .Include(c => c.CasinoTableGames).ThenInclude(y => y.TableGame) .Include(c => c.CasinoTableGames).ThenInclude(y => y.Manufacturer)...
Aishwarya's user avatar
  • 302
1 vote
2 answers
70 views

How do I join 3 tables in asp.net? 1st table is related to the 2nd only. 3rd is related to 2nd only

I have a problem. I want to join 3 tables in my asp.net web app but I am unsure on how to do that. Could you please help me? I want to join StudioId to a Movie table. However, Movie is not related in ...
md317's user avatar
  • 11
0 votes
1 answer
252 views

How to filter records using multiselect dropdown value combinations

I have a multiselect dropdown that a user can select more than 1 item at a time. Using this multiselect value I need to filter my datasource and return the parsed result to a gridview. Here is my code ...
user3920526's user avatar

15 30 50 per page
1
2 3 4 5
302