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 to db2 using ASP

Status
Not open for further replies.

amorous

Programmer
Sep 5, 2003
1,008
US
Hi All,

I am new to DB2. I have installed the IBM DB2 Client on my computer and also the different databases which i am going to use.

But i when i write the following connection string i am getting the error.

My connection String:
*****************************
<%StringConnect = &quot;Provider=DB2OLEODBC;&quot; & _
&quot;Data Source =DCCDB;&quot; & _
&quot;Network Transport Library=TCPIP;&quot; & _
&quot;Network Address=192.168.95.200;&quot; & _
&quot;User ID=xyza;&quot; & _
&quot;Password=scgmlk&quot;
%>

*****************************

Error:
*****************************
Error Type:
ADODB.Connection (0x800A0E7A)
Provider cannot be found. It may not be properly installed.

*****************************

Any suggestions.

Thanks in advance

VJ
 
I also tried:

Provider=DB2OLEDB, but still got the same error.

On the ASP page my code looks like:

Set rsObj = Server.CreateObject(&quot;ADODB.Recordset&quot;)
Set MdConnection = Server.CreateObject(&quot;ADODB.Connection&quot;)

MdConnection.Open StringConnect

Any ideas???

Thanks
VJ
 
Have you tried making an odbc connection?

Ben

----------------------------------------------
Ben O'Hara

&quot;Where are all the stupid people from...
...And how'd they get so dumb?&quot;
NoFX-The Decline
----------------------------------------------
 
Hi thanks for the reply.

Ya i guess i did ODBC connection.

Under User Data Sources I can see

&quot;DCCDB&quot; as Name
&quot;IBM DB2 ODBC Driver&quot; as Driver

Under System Data Sources, I see the same as above.

Under Drivers i see

&quot;IBM DB2 ODBC Driver&quot; 7.01.00.40 IBM corporation DB2CLI.DLL

What else should i do?

Thanks

VJ


 
To be honest, I know nothing about db2, I was just going along with the idea that if the odbc connection works, then you are 1.2 way there.
Have a look at
for details on the connection string & some ms support articles too.

Cheers

Ben

----------------------------------------------
Ben O'Hara

&quot;Where are all the stupid people from...
...And how'd they get so dumb?&quot;
NoFX-The Decline
----------------------------------------------
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top