Re: DataTable efficiency
Sébastien Lorion <[email protected]> Thu, 22 Nov 2007 12:08:58 +0800
| Newsgroups | gmane.comp.windows.devel.dotnet.cx |
|---|---|
| Message-ID | <[email protected]> |
You may want to take a look at my CSV reader found on Code Project: http://www.codeproject.com/cs/database/CsvReader.asp Sebastien On 11/21/07, Alan Baljeu <[email protected]> wrote: > My application uses a largish readonly database (CSV files, actually) con= sisting of several > tables. These tables are accessed somewhat frequently, and I want to mak= e this as efficient > as possible. I'm currently using plain DataTable objects produced by Odb= cAdapters and > queries. These tables are cached so I'm just searching in-memory tabl= es after that. My > queries look like "SELECT * FROM [{0}]" and occasionally "SELECT * FROM [= {0}] where [{1}] =3D > '{2}'". I'm thinking of splitting the latter into just table.Select("c= olname =3D value"). > > I have a nagging suspicion that the DataTable structure isn't super-effic= ient, or that > certain ways of using it are effcient while others aren't. > > Is this so? Are there certain things I should avoid? Do you recommend a= certain style for > efficient access? Is there a better approach that DataTable? > > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D > This list is hosted by DevelopMentor(R) http://www.develop.com > > View archives and manage your subscription(s) at http://discuss.develop.c= om > --=20 S=E9bastien www.sebastienlorion.com =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D This list is hosted by DevelopMentor=AE http://www.develop.com View archives and manage your subscription(s) at http://discuss.develop.com