Asp/odbc

Ricardo Coimbra

New Member
My db was made in progress 9.1C and is using the 3,60 Merant 32-Bit Progress SQL92 v9.1B to make the connection saw DSN. I receive the following message:
Microsoft OLE DB Provider for ODBC Drivers error '80004005'

[MERANT][ODBC PROGRESS driver]Insufficient information to connect to the data source. /lista1.asp, line 17

What it is made a mistake?
<html><body>

<table border=
"0" width="100%">

<tr>

<td width="7%"><img border="0" src="file:///C:/logo.gif"></td>

<td width="93%" valign="bottom"><b><font color="#0076B5" size="6">vallourec

do brasil
</font></b></td>

</tr>

</table>

<h1 align=
"center"><font size="5">Lista de eixos não entregues na linha2</font></h1>

<%

CXUserName="Administrator"

CXPassWord=""

CXColor="no"

Set CX = Server.CreateObject("ADODB.Connection")

CX.Open "tradutor"

Set RS = CX.Execute("Select referencia,datarastreabilidade,pkcabecalho from pub.referenciaetlinha2 where datarastreabilidade="" order by pkcabecalho")

RS.MoveFirst

Do While not RS.Eof%>

<p>Referencia: <%=RS.Fields("referencia")%> <br>

Data: <%=RS.Fields("datarastreabilidade")%> <br>

PKcabecalho: <%=RS.Fields("pkcabecalho")%> <br>

<hr>




<%RS.MoveNext

Loop%>

</body></html>

 

tri595

New Member
Dsn

Try this:-

OdbcConnection1.ConnectionString = ("DSN=database;UID=userid;PWD=passwd") /***** THIS INSTEAD OF CODE BELOW ****/

'("DRIVER=MERANT 3.60 32-BIT progress SQL92 v9.1C;SERVER=server3;DATABASE=database;USERID=userid;PASSWORD=passwd")

OdbcConnection1.Open()

OdbcCommand2.CommandText = ("select distinct COY from PUB.op_oheader")

OdbcCommand2.Connection = OdbcConnection1

dtrUnit = OdbcCommand2.ExecuteReader()

If dtrUnit.Read Then

While dtrUnit.Read()

MsgBox(dtrUnit.Item("coy"))

End While

OdbcCommand2.Dispose()
OdbcConnection1.Close()
End If

hope this helps
tri595
 
Top