c# - stackoverflow exception on System.Data.Linq.dll -


i'm working on asp.net web application. use linq sql orm data access layer (dal). in specific case of queries faces stackoverflow exception on clr level.

i use filter expression generator specific data (such load specific constrient) send more 1500 parameters store procedure.

note: consider rpc (remote procedure calling) limitation that's 2100 parameters in sql server default setting.

but don't know why face stackoverflow exception? it's interesting know problem occur on iis , no problem in asp.net web development server.

and i'm find out problem caused large number of parameters.

i grateful me?

exception detail

 public list<hsepersonnelcomplexpaging> selecthsepersonnelpaging(pagingpropertiesdto pagingprops, out int reccount)     {         using (hrpaidtimeoffdatacontext db = new hrpaidtimeoffdatacontext(dbhelper.getconnectionstring()))         {             expression<func<hsepersonnelcomplexpaging, bool>> expr =                 predicatebuilder.getfilterexpression<hsepersonnelcomplexpaging>(pagingprops);             db.deferredloadingenabled = false;              var items = @ in db.hsepersonnels                         at.isdeleted == false                         select new hsepersonnelcomplexpaging                         {                             id = at.hsepersonnelid,                             personnelyno = at.personnelyno,                             name = at.name,                             family = at.family,                             birthplace = at.birthplace,                             birthdate = at.birthdate,                             father = at.father,                             idno = at.idno,                             nationalcode = at.nationalcode,                             isnotactive =  at.isnotactive,                             isdeleted = at.isdeleted,                             insertdate = at.insertdate,                             updatedate = at.updatedate,                             insertentuseraccountid = at.insertentuseraccountid                          };             var result = items.where(expr);             reccount = result.count();             return                 result.applysortexpression(pagingprops.sortset).skip(pagingprops.currentpageindex *                                                                      pagingprops.currentpagesize).take(                                                                          pagingprops.currentpagesize).tolist();         } 

the problem might lie in predicate you're building. when enumerate expression (which you're doing in call count()), linq sql walk down expression tree determine you're trying query. possible somewhere you're creating cyclic reference?


Comments

Popular posts from this blog

javascript - Laravel datatable invalid JSON response -

java - Exception in thread "main" org.springframework.context.ApplicationContextException: Unable to start embedded container; -

sql server 2008 - My Sql Code Get An Error Of Msg 245, Level 16, State 1, Line 1 Conversion failed when converting the varchar value '8:45 AM' to data type int -