Click here to Skip to main content
15,888,527 members
Home / Discussions / C#
   

C#

 
GeneralRe: Gmail Port 465 Send Mail Error Pin
Anubhava Dimri16-Feb-11 1:17
Anubhava Dimri16-Feb-11 1:17 
GeneralRe: Gmail Port 465 Send Mail Error Pin
Dave Kreskowiak16-Feb-11 2:26
mveDave Kreskowiak16-Feb-11 2:26 
QuestionDataGridViewTextBoxEditingControl autocomplete conflict with wrapmode [modified] Pin
reza assar14-Feb-11 19:37
reza assar14-Feb-11 19:37 
Questionqueries with coding Pin
Rei ho14-Feb-11 18:43
Rei ho14-Feb-11 18:43 
QuestionRedirect after xsl file is downloaded Pin
S.Aijaz14-Feb-11 18:12
S.Aijaz14-Feb-11 18:12 
QuestionWhat is the better approach between IQueryable and IEnumerable ? Pin
Nadia Monalisa14-Feb-11 15:13
Nadia Monalisa14-Feb-11 15:13 
AnswerRe: What is the better approach between IQueryable and IEnumerable ? Pin
PIEBALDconsult14-Feb-11 17:16
mvePIEBALDconsult14-Feb-11 17:16 
GeneralRe: What is the better approach between IQueryable and IEnumerable ? Pin
Nadia Monalisa14-Feb-11 17:59
Nadia Monalisa14-Feb-11 17:59 
Hi,
Thanks a lot for your reply.

Actually, I am re-factoring my Web Application for better maintainability and memory performance. I host my web application in a shared hosting where I am allowed to use a very limited amount of RAM.

In my Web Application, I used LINQ to SQL where my Code Behind files are directly calling the DataContext class generated by LINQ to SQL Classes. I want to encapsulate the call of DataContext in a Business Logic Layer. I am very much tempted to return IEnumerable Objects from my Business Logic Layer to the Presentation Layer instead of IQueryable objects as I know, IQueryable object means, differed SQL query execution. Moreover, when using IQueryable object, I cannot use most of the LINQ features that are available for LINQ to Object. Because, LINQ to SQL does not have similar translation for many C# methods.

Now, My question, Is it more memory efficient to work with IQueryable object instead of IEnumerable object ? So far I can guess, using IQueryable means, my RAM will be free from loading the whole database table. But If I convert the IQueryable to IEnumerable by calling ToList() or ToArray(), then, the whole object will be loaded into the RAM and reduce performance. Is my guess right ? Would you please give me a better direction for this scenario ?
GeneralRe: What is the better approach between IQueryable and IEnumerable ? Pin
PIEBALDconsult15-Feb-11 1:53
mvePIEBALDconsult15-Feb-11 1:53 
AnswerRe: What is the better approach between IQueryable and IEnumerable ? Pin
dasblinkenlight14-Feb-11 21:25
dasblinkenlight14-Feb-11 21:25 
GeneralRe: What is the better approach between IQueryable and IEnumerable ? Pin
PIEBALDconsult15-Feb-11 2:02
mvePIEBALDconsult15-Feb-11 2:02 
GeneralRe: What is the better approach between IQueryable and IEnumerable ? Pin
dasblinkenlight15-Feb-11 2:31
dasblinkenlight15-Feb-11 2:31 
GeneralRe: What is the better approach between IQueryable and IEnumerable ? Pin
PIEBALDconsult15-Feb-11 4:19
mvePIEBALDconsult15-Feb-11 4:19 
GeneralRe: What is the better approach between IQueryable and IEnumerable ? Pin
dasblinkenlight15-Feb-11 5:15
dasblinkenlight15-Feb-11 5:15 
GeneralRe: What is the better approach between IQueryable and IEnumerable ? Pin
PIEBALDconsult15-Feb-11 8:32
mvePIEBALDconsult15-Feb-11 8:32 
GeneralRe: What is the better approach between IQueryable and IEnumerable ? Pin
dasblinkenlight15-Feb-11 9:40
dasblinkenlight15-Feb-11 9:40 
GeneralRe: What is the better approach between IQueryable and IEnumerable ? Pin
PIEBALDconsult15-Feb-11 10:03
mvePIEBALDconsult15-Feb-11 10:03 
GeneralRe: What is the better approach between IQueryable and IEnumerable ? Pin
PIEBALDconsult15-Feb-11 10:09
mvePIEBALDconsult15-Feb-11 10:09 
QuestionControl Speaker Volume Pin
Kevin Marois14-Feb-11 8:21
professionalKevin Marois14-Feb-11 8:21 
AnswerRe: Control Speaker Volume Pin
DaveyM6914-Feb-11 9:15
professionalDaveyM6914-Feb-11 9:15 
GeneralRe: Control Speaker Volume Pin
Kevin Marois14-Feb-11 10:27
professionalKevin Marois14-Feb-11 10:27 
GeneralRe: Control Speaker Volume Pin
DaveyM6914-Feb-11 10:58
professionalDaveyM6914-Feb-11 10:58 
GeneralRe: Control Speaker Volume Pin
Kevin Marois14-Feb-11 11:03
professionalKevin Marois14-Feb-11 11:03 
GeneralRe: Control Speaker Volume Pin
Kevin Marois14-Feb-11 11:36
professionalKevin Marois14-Feb-11 11:36 
GeneralRe: Control Speaker Volume Pin
DaveyM6914-Feb-11 11:45
professionalDaveyM6914-Feb-11 11:45 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.