COPY/replicate database in MySql server

User avatar
sal21
PlatinumLounger
Posts: 4368
Joined: 26 Apr 2010, 17:36

COPY/replicate database in MySql server

Post by sal21 »

I use vb6 classic and Mysql server in my project...
My conn:

Code: Select all

Public Sub APRI_CONNESSIONE()

    On Error GoTo Err_SomeName

    Dim PC_OPERANTE As String

    PC_OPERANTE = Environ$("COMPUTERNAME")

    Set CONN = New ADODB.Connection
    With CONN
        .ConnectionString = "Driver={MySQL ODBC 3.51 Driver};Server=localhost;Port=3306;Database=l_mysql;User=root; Password=sal21;Option=3;"
        .CommandTimeout = 1000
        .ConnectionTimeout = 1000    'Tempo in mS prima che il tentativo di connessione vada in TimeOut
        .CursorLocation = adUseServer
        .Open
    End With

Exit_SomeName:
    Exit Sub

Err_SomeName:
    MsgBox Err.Number & Err.Description
    Resume Exit_SomeName

End Sub
In this Mysql server have a database named l_mysql.
Is possible to copy/replicate this database in the same instance with a new named l_mysql_1.?

note:
- all via VB6 code
- Naturally with all tables and maintan all property of field, indexed fields, name ecc...

User avatar
sal21
PlatinumLounger
Posts: 4368
Joined: 26 Apr 2010, 17:36

Re: COPY/replicate database in MySql server

Post by sal21 »

SORRY FOR UP:-)

User avatar
HansV
Administrator
Posts: 78620
Joined: 16 Jan 2010, 00:14
Status: Microsoft MVP
Location: Wageningen, The Netherlands

Re: COPY/replicate database in MySql server

Post by HansV »

I'm afraid I have no idea how to copy a MySQL database using VB6.
Best wishes,
Hans

User avatar
sal21
PlatinumLounger
Posts: 4368
Joined: 26 Apr 2010, 17:36

Re: COPY/replicate database in MySql server

Post by sal21 »

HansV wrote:I'm afraid I have no idea how to copy a MySQL database using VB6.
No prob! My friend!

You know in this case 99,9999999 of all :grin: :hairout: :grin: :grin: :grin: :grin: not is the same from me :sad: