performance - How to speed up a LogParser application in ASP.NET -


i've developed asp.net application receives input user sql query ran logparser. (this input kept in "sql1" string. works, works slowly. log file of 60 mb, i've received outofmemory exception. i'm sharing code down below, ideas speed up? there way directly insert ilogrecordset object datagrid, without first converting dataset?

            logquery ologquery = new logquery();             comiisw3cinputformat eventlog = new comiisw3cinputformat();              ilogrecord numreq = null;             ilogrecordset numset = null;              numset = ologquery.execute(sql1, eventlog);             datatable querytable = new datatable("query");             (int = 0; < numset.getcolumncount(); i++)             {                 datacolumn col = new datacolumn();                 col.columnname = numset.getcolumnname(i);                 switch (numset.getcolumntype(i))                 {                     case 1:                         col.datatype = type.gettype("system.int32");                         break;                     case 2:                         col.datatype = type.gettype("system.double");                         break;                     case 4:                         col.datatype = type.gettype("system.datetime");                         break;                     default:                         col.datatype = type.gettype("system.string");                         break;                 }                 querytable.columns.add(col);             }              while (!numset.atend())             {                 numreq = numset.getrecord();                 datarow row = querytable.newrow();                  (int = 0; < numset.getcolumncount(); i++)                     row[i] = httpputility.htmlencode(convert.tostring(numreq.getvalue(i)));                  querytable.rows.add(row);                 numset.movenext();             }              dataset ds = new dataset();             ds.tables.add(querytable);              querygrid.datasource = ds;             querygrid.databind(); 


Comments

Popular posts from this blog

delphi - How to convert bitmaps to video? -

jasper reports - Fixed header in Excel using JasperReports -

python - ('The SQL contains 0 parameter markers, but 50 parameters were supplied', 'HY000') or TypeError: 'tuple' object is not callable -