Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Connecting VB and DB2

Status
Not open for further replies.

Prukrutha

Programmer
Dec 11, 2002
2
US
Hi,
How to connect DB2 and VB?
i have heard that IBM-DB2 can be connected to VB thro ODBC drivers.

But pls, it will be very helpful, if i know the full process?

I'm very much new to IBM-DB2.

Thanx and Regds
Prukrutha
 
If you have DB2 for Windows installed on your machine, you should have samples of how to connect to DB2 through VB in 'Sqllib\Samples\VB'. In fact, I believe you need it installed on your machine in order to get the drivers required by ODBC. "Connect.vbp" and "Sample.vbp" are 2 examples containing code to connect to DB2.
 
Could you please mention the DB2 that you are going to connect to is on which platform? (Windows,Unix,Os/390 etc.)
 
Hi,
I want to connect DB2 on OS 390 and not DB2 on windows.
Pls help.

Regds
Prukrutha.K
 
Prukrutha

For DB2 for OS/390, you will need to install DB2 connect ... Then you will have to catalog the remote DB2 Subsystem on the client (You can do this using Client Config Assistant - db2cca) ... When cataloging ensure that you define it as a ODBC data source... Once done, DB2 is like any other ODBC DSN

HTH

Cheers

Sathyaram
 
Prukrutha.K,

You should concider using the IBM OLE DB Provider for DB2. Not sure what you application will be doing but this provider gives ADO applications the ability to extract or query DB2 using the natave OLE interface. Hence you'll get better performance over ODBC.

See "Writing Applications Using the IBM OLE DB Provide for DB2" for more details (
Good luck.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top