Hi Michael,

This seems to be better than executing a batch file. 
But still, its not efficient as large database restorations would
require innumerable queries to be executed.
Wish MySQL had a non-proprietary SQLDMO like API !!

Regards,
Nawal Lodha.

-----Original Message-----
From: Michael Loftis [mailto:[EMAIL PROTECTED] 
Sent: Monday, June 14, 2004 2:53 PM
To: Nawal Lodha; [EMAIL PROTECTED]
Subject: Re: How to Restore MySQL Database from VB?

\. is the MySQL CLI/monitor SOURCE command.

read your file in one statement at a time and execute it (search for
unquoted/unescaped ;'s at the end of the statements)

--On Monday, June 14, 2004 11:32 +0530 Nawal Lodha <[EMAIL PROTECTED]>
wrote:

> Hi all,
> I wish to restore an sql file in a mysql database though VB. One way 
> of doing it is writing the Create Database command and the mysql 
> restore command 'mysql -options < sql_file' in a batch file and
executing it.
>
> Is there any other better way of doing it?
>
> Btw, I try to make an ADO connection and call the command "\.
sql_file"
> using Execute/Open method of Connection Object. But that doesn't seem 
> to work.
>
> Thanks,
> Nawal Lodha.



--
Michael Loftis
Modwest Sr. Systems Administrator
Powerful, Affordable Web Hosting



--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]

Reply via email to