c# - Do LINQ queries use the processing power of the machine running the program or the server hosting the database? -
if have following code
mydatacontext _datacontext = new mydatacontext(myconnectionstring); list<airplane> entiretable = _datacontext.airplanes list<airplane> propellerplanes = new list<airplane>(); foreach(airplane p in entiretable){ if(p.ispropellerplane) propellerplanes.add(p); } when code runs, i'm assuming processing power query coming computer running program.
but when code runs:
list<airplane> propellerplanes = _datacontext.airplanes.where(a => a.ispropellerplane).tolist(); is processing power running query coming computer running program, or computer sql server installed on i've connected in connection string?
i'm assuming talking linq sql (there other adapters), in case, linq sql driver translates linq query regular sql query part.
so answer question, of work done computer running sql server.
Comments
Post a Comment