473,670 Members | 2,511 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Saving table

I have a dataTable in my memory(session) .

Can I save this table into sql dataTable in one step?

Now, I'm iterating through the records and saving record by record with
command object.

But it's slow process. Any idea?

Regards,Simon

Sep 26 '06 #1
2 1336
I don't think you can do much more than tuning your database performance.

--
Eliyahu Goldin,
Software Developer & Consultant
Microsoft MVP [ASP.NET]
"simonZ" <si*********@st udio-moderna.comwrot e in message
news:e4******** ******@TK2MSFTN GP04.phx.gbl...
>I have a dataTable in my memory(session) .

Can I save this table into sql dataTable in one step?

Now, I'm iterating through the records and saving record by record with
command object.

But it's slow process. Any idea?

Regards,Simon

Sep 26 '06 #2
Hi,

I already find it and it works perfect.
I used SQLBulkCopy.

regards,Simon

"Eliyahu Goldin" <RE************ **************@ mMvVpPsS.orgwro te in
message news:uc******** ******@TK2MSFTN GP03.phx.gbl...
>I don't think you can do much more than tuning your database performance.

--
Eliyahu Goldin,
Software Developer & Consultant
Microsoft MVP [ASP.NET]
"simonZ" <si*********@st udio-moderna.comwrot e in message
news:e4******** ******@TK2MSFTN GP04.phx.gbl...
>>I have a dataTable in my memory(session) .

Can I save this table into sql dataTable in one step?

Now, I'm iterating through the records and saving record by record with
command object.

But it's slow process. Any idea?

Regards,Simo n


Sep 26 '06 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

13
7402
by: Stuart McGraw | last post by:
I haven't been able to figure this out and would appreciate some help... I have two tables, both with autonumber primary keys, and linked in a conventional master-child relationship. I've created forms for both those tables, and inserted the child table form into the master table form as a subform. It works just as it is supposed to, in that I can create a new master record, and then add detail records.
1
1896
by: Paul H | last post by:
Say I have a table called tblPeopleInfo, one of the fields in the table is called FavouriteFruit. The FavouriteFruit field is a lookup field and will contain Apples, Oranges, Grapes etc..The list can be added to by users of the database. What is the best way to construct this lookup? Should it lookup a Table/Query or a Value List? If it looks up to a Table/Query should the lookup table just have a single "text" field or should it have...
14
1882
by: MLH | last post by:
GHudson has working procedures posted at http://www.access-programmers.co.uk/forums/showthread.php?t=66320 They work. Relationships, however, and some minor default settings are not preserved. Reestablishing some default settings and settings is a small price to pay for a set of text files that may save your database from total loss #AND# seem to remove the database bloat as well. I was wondering if someone knew how to preserve the...
4
3288
by: dale zhang | last post by:
Hi, I am trying to save and read an image from MS Access DB based on the following article: http://www.vbdotnetheaven.com/Code/Sept2003/2175.asp Right now, I saved images without any errors. After reading the ole object from db, I saved it to C: as file1.bmp and displayed on the web. But it can not be displayed. After I manually sent the file to wordpad, it shows
18
3785
by: TORQUE | last post by:
Hi, Im wondering if anyone can help me with a problem. I have a form with more than 50 unbound fields. Some of the fields will be blank from time to time. This seems to be where im having trouble. I have tried keeping some of the fields bound and when I use the save button it has been saving as 2 different records. This is unacceptable. This is what I have, can anyone help me out with this?
1
2596
by: Magnus | last post by:
I'm testing walkthrough saving data to a Database (Multiple Tables). http://msdn2.microsoft.com/en-us/library/4esb49b4(VS.80).aspx In the famous Customer/Order example, I'm getting referential integrity problems "The INSERT statement conflicted with the FOREIGN KEY constraint..." if the identity/primary key column is "out of sync" with the identity value in the database. I can easily acheive this f.ex. by pressing add new record,...
2
2219
by: jessDMiller | last post by:
I have no clue why the data from the form isn't saving into the database. What am I doing wrong? addAnnounce.php: <td align=top> <form action="index2.php" method="post">Heading:<br /><textarea name="heading" cols="50" rows="10"></textarea><br /><br />Announcement:<br /> <textarea name="announce" cols="50" rows="10"></textarea> <br /><br />Date:<br /><textarea name="date" cols="50" rows="10"></textarea><br /><br /><input...
2
3559
by: tomlebold | last post by:
It takes five minutes when using object linking and embedding to save a PDF file using a normal from. The data type is image in an SQL Sever table. We are trying to keep track of the legal documents that we have purchased. Is their a better technique to use, rather saving the PDF file . Could we save the path to a text or varchar datatype.
9
1646
by: =?Utf-8?B?TWlrZTk5MDA=?= | last post by:
I save a number in the table and want to get that number again, but the number I get has lower precision than I expect. For example, when I divide 10/3 I get 3.3333333333333335 if the variable is of type Double. But saving this result into a table with a column of type Double decreases the precision to 3.333333333333333 , so when I get this number and multiply it 10 I do not get that exact number which is 10. How can I solve this...
1
1198
by: AlisonD | last post by:
have a database that I am using a look up table. On the form the whole table appears. I have name,telephone number,fax number,address, licencesdate. I want to be able to choose the correct name for different enteries. So I need help with on how to save the data onto another table. If someone can take through from start to finish I believe my mistake is when I designed the table. I did the lookup table and put that into the form then figure out...
0
8466
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8384
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
8901
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
8813
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
8659
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
6212
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
4208
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
1
2799
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
2037
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.