Startseite ¦  was ist neu ¦  programmier tips ¦  indy artikel ¦  intraweb artikel ¦  informationen ¦  links ¦  interviews ¦  sonstiges
kylix ¦  tutorials ¦  online shop ¦  fotos ¦  Add&Win Gewinnspiel


Willkommen Gast. Bitte einloggen oder registrieren.
23.05.2013, 22:48:49
Übersicht Hilfe Suche Einloggen Registrieren

+  SwissDelphiCenter Forum
|-+  German Forums
| |-+  Datenbank Forum
| | |-+  Copy data from a table to another table
« vorheriges nächstes »
Seiten: [1] Drucken
Autor Thema: Copy data from a table to another table  (Gelesen 2522 mal)
isr123
Newbie
*
Offline Offline

Beiträge: 8


« am: 03.02.2009, 11:23:09 »

Hello all,

How to copy data from a table on a server to a table on another server,
using ADO.

How to use a Stored Procedure to copy the data.

Many thanks
I. Nemlich
Gespeichert
grenzgaenger
Global Moderator
Full Member
*****
Offline Offline

Beiträge: 232


« Antworten #1 am: 11.02.2009, 08:32:31 »

hello isr123,

I think, this is not possible with stored procedures. read the tables which you want with a query or a tTable component and transfer the date to the other TADOConnection and insert them into the database ... has the table the same structure so you can use such kind of ..

t1.first
while not t1.eof do
begin
 t2.insert;
 for i := 0 to t1.fieldcount -1 do
   t2.fields := t1.fields;
 t2.post;
 t1.next;
end;


<HTH> GG
Gespeichert
isr123
Newbie
*
Offline Offline

Beiträge: 8


« Antworten #2 am: 18.02.2009, 22:11:47 »

This is actually the way I am performing copy data between 2 servers but it is very slowwwww!! and I am looking for a quicker solution.

Many thanks

I. Namelich
Gespeichert
Seiten: [1] Drucken 
« vorheriges nächstes »
Gehe zu:  


Einloggen mit Benutzername, Passwort und Sitzungslänge

Powered by MySQL Powered by PHP Powered by SMF 1.1.11 | SMF © 2006, Simple Machines LLC Prüfe XHTML 1.0 Prüfe CSS