Best approach, Loading Tables

G

Guest

I need to create a sqlclient app to modify look up tables on a sql dbase,
there are some 8~10 tbls I think. I have some general idias of what to do,
but I have never done something like this, I am using VBExpress 2005. I
would be great if someone could give a roadmap of the steps to follow to load
the data to the client, concidering efficency and speed. I specially having
problem figuring out wich classes to use to load each table, maintaining the
constraints and all of that. If someone could give some idias I would really
appreciate it. TIA
 
G

Guest

Thank you Ryan.
I was looking not for the step by step guide, I was more concerned with the
way to load the tables, whether using a DataAdapter per table of one for all.
Something like this. I still reading and gathering info. But if someone who
has done something like this (data client app), would tell me what to look
for or watch out, it would help me get ready faster.
 
E

Earl

You can use and reuse the data adapter as needed. As you can see from this
simple snippet, the dataadapter does not care about which table it is
sending data to and from -- it just needs to know the appropriate
Select/Update/Insert/Delete commands (in the following, "cmd" is a
paramterized command that calls a stored procedure). Nor does it matter what
datatable it is to fill -- it simply needs the name of the datatable.

SqlDataAdapter da = new SqlDataAdapter();
da.SelectCommand = cmd;
da.Fill(dt);
 

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