Performance issue

G

Guest

Hello,

Please which perform better for searching in a sql ce db table:

1) using an sqlCeAdapter and querying the table then loading a datatable
with sqlCeAdapter and bind it to a data grid or

2)Loading the datatable using the sqlCeAdapter with all the table data then
searching in the datatable then bind it to the data grid

Thank you.
 
M

Miha Markic [MVP C#]

Hi Philip,

I would go with filtered query. It'll certainly perform better in general.
 
G

Guest

Can you please explain to me in more detail what do you mean?
here is what i want to do:

I have two queries to make and two data to display in a datagrid.

1) first query and first data to display:
a)query: the user enters some characters, the query selects the rows from
the table
that have a primary which begins with this sequence of characters.
b)dislay: the primary key of these selected rows are displayed in a datagrid
(one column).

2)Second query and second data display:
a)query: the user selects one row from the rows in the datagrid, the query
consists of selecting all the attributes of the selected row(28 attributes)
b)all the attributes of this single row are than displayed in the datagrid.

Which scenario do i choose for having the best possible performance knowing
that rows have 28 attributes and the table contains up to 10.000 row.

Thank you.

Miha Markic said:
Hi Philip,

I would go with filtered query. It'll certainly perform better in general.

--
Miha Markic [MVP C#] - RightHand .NET consulting & development
www.rthand.com
Blog: http://cs.rthand.com/blogs/blog_with_righthand/
SLODUG - Slovene Developer Users Group www.codezone-si.info

Philip Germanos said:
Hello,

Please which perform better for searching in a sql ce db table:

1) using an sqlCeAdapter and querying the table then loading a datatable
with sqlCeAdapter and bind it to a data grid or

2)Loading the datatable using the sqlCeAdapter with all the table data
then
searching in the datatable then bind it to the data grid

Thank you.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top