Link to home
Start Free TrialLog in
Avatar of Hypermechanic
Hypermechanic

asked on

Replication from AS400/PRMS to Microsoft SQL2000. HOW TO PLEASE.

I am trying to replicate the data contain within our AS400 running INFOR's "PRMS" to a SQL 2000 server.
I would like to do this via ODBC. I do not see AS400 driver in the ODBC list. At this point I feel some Expert advice or better yet a How To is in order.

If you would please.
ASKER CERTIFIED SOLUTION
Avatar of nmcdermaid
nmcdermaid

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Hi
i would use ADODB, this is the same as ODBC but you can create the connections dynamically.
You could create a list of files, libraries etc in Excel the run down the list abd populete the sql table.

in excel VB you get acces to ADODB via F11, vb macro, Tools/References then select any Microsoft DAO 3.x Object library.

Public Sub AS400()
 
Dim con As New ADODB.Connection
Dim rs As New ADODB.Recordset
Dim No400 As Boolean
Dim Userid As String
 
On Error GoTo OhEck
 
con.Open "PROVIDER=IBMDA400;Data Source=999.999.999.999;USER ID= ;PASSWORD= ;"
 
Set rs.ActiveConnection = con
 
rs.Open ("SELECT * FROM MYLIB.MYFILE WHERE Condition")
do while not rs.eof
// process db to table move
enddo ;
 
 
rs.Close
 
End
 
Exit Sub
 
OhEck:
 
MsgBox "Cann not connect to the AS/400 - Downloads are not possible", vbInformation, cHeading
End
 
End Sub
	 

Open in new window

Avatar of nmcdermaid
nmcdermaid

I don't think he's goin to have the IBMDA400 provider until the client tools get installed.
Hi
nmcdermaid: gave the correct answer in that the ODBC driver comes on the client access tools CD.
Once the software is installed it appears in the systems DSN.

I simply gave an alternate to ODBC by using ADODB.