score:1
"linq" includes linq to objects, linq to sql, etc. you can certainly query in memory, but maybe you should wait until you've done a performance analysis before optimizing. you may optimize the wrong thing.
score:1
ad hoc, loading up to 250 megabytes of data into client memory seems not to be such an good idea. if you have it memory, you can use linq to object and save the database roundtrips.
the problem is that your data is hierarchical and you have to fetch one row, examin it, and retrieve the releated rows and this causes so many roundtrips.
you could use lazy loading to retrieve more and more rows into client memory during the runtime of your program and perform more and more queries in memory when the working set stabilizes. but this will only help if rows are accessed multiple times and not only once or twice.
another solution might be to create recursive views or stored procedure using common table expression that retrieve releate rows up to some distance from a given row.
Source: stackoverflow.com
Related Query
- Can you use LINQ with in memory objects rather than SQL Server queries to improve performance?
- Can I use C# string interpolation with Linq to SQL
- How can you use LINQ to find Azure AD users with specific licenses using the Azure AD Graph API Client Library 2.0
- How can you use LINQ to cast from a collection of base class objects to a filtered list of their respective subclasses?
- How can I issue a LINQ query to a SQL Server to check if a column value starts with a word?
- Accessing SQL Server time in code with LINQ
- How I can write something similar to Linq .Any() when writing sql server queries
- How can you use Linq result with RDLC report?
- Storing binary objects in SQL Server with LINQ
- How can I use two different databases with Linq to SQL in Linqpad?
- Can I reasonably go five levels deep with a .Include in LINQ and a SQL Server 2012 Backend?
- How can I use Aggregate Operators in Linq queries with multiple tables?
- What can I do to resolve a "Row not found or changed" Exception in LINQ to SQL on a SQL Server Compact Edition Database?
- Instantiate empty IQueryable for use with Linq to sql
- How can you handle an IN sub-query with LINQ to SQL?
- Can you use LINQ types and extension methods in IronPython?
- How do you use LINQ with Sqlite
- Odd behavior in LINQ to SQL with anonymous objects and constant columns
- Can I capture a local variable into a LINQ Expression as a constant rather than a closure reference?
- How/Can I use linq to xml to query huge xml files with reasonable memory consumption?
- How can you do custom sorting in LINQ with null always on the end?
- Can you reverse order a string in one line with LINQ or a LAMBDA expression
- How to use distinct with group by in Linq to SQL
- How can I directly execute SQL queries in linq
- How can I use Linq with a MySql database on Mono?
- LINQ to SQL - Why can't you use a WHERE after an ORDER BY?
- How can you update a Linq Expression with additional parameters?
- Can I use LINQ to check if objects in a list have a unique ID?
- Can I use a collection initializer with LINQ to return a fully populated collection?
- How can you see the sql that is causing an error on SubmitChanges in LINQ to SQL?
More Query from same tag
- Showing data from different tables with Linq C# Asp.net
- Problem in creating database through code first approach
- C# Linq non-vowels
- Call SelectMany with Expression.Call - wrong argument
- How to do a "Select" in Linq when there is no result
- Cannot convert string to int32 LINQ
- c# Fluent SQL Helper - Syntax improvement
- How can I use lazy loading logic of pagination to retrieve FileSystem kind of hierarchichal data
- Use reflection and lambda expression with linq
- Optimize Web API call
- Add nodes and grouping
- How to query this two XML files using C#?
- Chopping string with LINQ
- Group-by specific time ranges in LINQ
- C# code or algorithm to quickly calculate distance between large strings?
- Can I 'flatten' an XDocument with Linq?
- Is it possible to implement RemoveAll() on EntityCollection<T>?
- Linearize with Linq in C#
- Create a ASP.net login system based on a existing table?
- LINQ GroupBy with Sum
- Performance of FirstOrDefault()
- MS CRM 2011 CrmSvcUtil gives error
- How to cast an `IEnumerable<Unknown T>` to `IEnumerable<Whatever>`
- Cant Query XML XElement if loaded by file
- Simplify entity framework query
- Use LINQ to find duplicated rows (with list of specified columns)
- Linq conditional select with null member collection
- ArgumentOutOfRangeException While trying to get the list of DataTable columns
- How Do You Exclude Items From A Search Query
- Get the previous item from a list through the index of the later