Re: slow insert a lot of row from table adapter to sql table, improve?



alex wrote:
I have to insert a lot of rows from a tableadapter to a sql table.
The operation is slow because table adptert send a single insert
command for each row.
Is there any way to have it with only one batch command? Or a faster
solution?

I think this is a dotnet question but I'm not sure because I've never heard
of a "tableadapter". If it is a dotnet question, then:
There was no way for you to know it (except maybe by browsing through some
of the previous questions in this newsgroup before posting yours - always a
recommended practice) , but this is a classic ADO newsgroup. ADO.Net bears
very little resemblance to classic ADO so, while you may be lucky enough to
find a dotnet-knowledgeable person here who can answer your question, you
can eliminate the luck factor by posting your question to a group where
those dotnet-knowledgeable people hang out. I suggest
microsoft.public.dotnet.framework.adonet.

If you are using SQL Server, then you have all sorts of bulk insert options
which you can read about in BOL.

--
Microsoft MVP - ASP/ASP.NET
Please reply to the newsgroup. This email account is my spam trap so I
don't check it very often. If you must reply off-line, then remove the
"NO SPAM"


.



Relevant Pages

  • Re: Solid Edge or Solid Works on 3D
    ... There is an OPEN newsgroup that does not require a webkey account that is ... This will keep whatever command you're ... > mate relatioship it will be automatically converted to a planar align. ... > - Update Links and Update Relationship commands are in the main toolbar. ...
    (comp.cad.solidworks)
  • Re: Monitoring and Alerts
    ... I have discussed with other engineers and the command may have some ... Microsoft CSS Online Newsgroup Support ... This newsgroup only focuses on SBS technical issues. ... |> | Subject: Re: Monitoring and Alerts ...
    (microsoft.public.windows.server.sbs)
  • Re: Can not access Web and FTP sites from Internet
    ... Microsoft CSS Online Newsgroup Support ... Do you have ISA Server installed? ... >internal clients are connected directly to the router. ... >the command prompt of command window. ...
    (microsoft.public.windows.server.sbs)
  • Re: faulty companyweb
    ... when I ran the command on my test machine ... Web Site Document Sharing and File Storage with Windows SharePoint Services ... This newsgroup only focuses on SBS technical issues. ... you may want to contact Microsoft CSS directly. ...
    (microsoft.public.windows.server.sbs)
  • RE: Reinstall Shared Fax on XP SP2 Clients?
    ... Yes, thanks, issue resolved with noted adjustments to the command line. ... Does Bill's suggest resolve you issue? ... Microsoft CSS Online Newsgroup Support ... This newsgroup only focuses on SBS technical issues. ...
    (microsoft.public.windows.server.sbs)