Does a DataView increase the speed of an DataTable.Select ?

  • Thread starter Thread starter Frank Hauptlorenz
  • Start date Start date
F

Frank Hauptlorenz

Hi out there,

I use an algorithm which uses different selects in loops and needs some
optimizations.
I read in a book that when I define a DataView with a specific sort my
DataTable.select is faster.
(The tables have a primary key and the select is containing these fields).

Is it true?

Thanks,
Frank
 
Whether you define a view or not, a view is used. By specifying a view, even
the default view, you narrow the "search time" (for lack of a better word).
You might also improve this further by creating a more specific view.

In general, explicit code is faster, but it is not always true. It is,
however, more specific to intent.

--
Gregory A. Beamer
MVP, MCP: +I, SE, SD, DBA

Subscribe to my blog
http://gregorybeamer.spaces.live.com/lists/feed.rss

or just read it:
http://gregorybeamer.spaces.live.com/

********************************************
| Think outside the box! |
********************************************
 
Back
Top