Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Where is IQueryable in the .NET Compact Framework?

I have started to develop a repository using LINQ to SQL against SQL CE in a Windows project. This works fine. However, when I went to port the code over to .NET CF for a Windows Mobile application, the IQueryable does not appear to exist.

What is the best way to make this work across Mobile and Desktop?

like image 727
Chad Avatar asked Feb 01 '10 05:02

Chad


1 Answers

It simply isn't there - most notably, because neither is Expression (although you can reintroduce pieces of that if you need).

Simply, you'll have to limit yourself to "regular" code for data-access (LINQ-to-SQL etc) / services (ADO.NET Data Services etc). Of course, when you have data from whatever source, you can still use IEnumerable<T>, so there are plenty of local options for data query.

like image 181
Marc Gravell Avatar answered Oct 05 '22 22:10

Marc Gravell