Page 1 of 1

Generate Script

Posted: Thu 03 Mar 2011 02:23
by azis
I have some table, that is to be send in branch one to branch others or the other way. i want to generate script insert into or delete , each rows


what is posible by use of MyDump or Script.


thank's

Azis

Posted: Thu 03 Mar 2011 12:24
by AndreyZ
Hello,

You should use the TMyDump component that serves to store a database or its parts as a script and to restore a database from the received script. Here is an example of backing up a table:

Code: Select all

MyDump.TableNames := 'your_table';
MyDump.BackupToFile('backup_file_name');
And here is an example of restoring from backup file:

Code: Select all

MyDump.RestoreFromFile('backup_file_name');
For more information, please read the MyDAC documentation.