Insert de donnees dans une table
Bonjour,
J'aimerais transferer une table d'une bdd sqlserver vers mysql en utilisant les drivers ODBC. Les deux tables on la meme definition et j'utilise GetRows pour recuperer les donnees de la premiere base de donnee.
Code:
1 2 3 4 5 6 7 8
|
Dim Rs As New ADODB.Recordset
Dim SQLConnection As New ADODB.Connection
SQLConnection.Open("connectionstring")
SQLConnection.CommandTimeout = 0
Rs.Open("DimAccount", SQLConnection, ADODB.CursorTypeEnum.adOpenStatic, ADODB.LockTypeEnum.adLockReadOnly)
Dim datatable As New Object
datatable = Rs.GetRows() |
Cela me retourne un objet a 2 dimentions que je ne sais pas comment parser
Comment faire pour l'inserer dans ma table mysql?
Code:
1 2 3 4 5 6
|
Dim Rs2 As New ADODB.Recordset
Dim SQLConnection2 As New ADODB.Connection
SQLConnection2.Open("Dsn=mysql;")
SQLConnection2.CommandTimeout = 0
Rs2.Open("DimAccount", SQLConnection2, ADODB.CursorTypeEnum.adOpenDynamic, ADODB.LockTypeEnum.adLockBatchOptimistic) |
Merci pour votre aide