Oracle 8i/NT and ASP/ NT

Results 1 to 2 of 2

Thread: Oracle 8i/NT and ASP/ NT

  1. #1
    Join Date
    Dec 1969

    Default Oracle 8i/NT and ASP/ NT

    I have set up an Oracle8i db on NT which uses ODBC and TCPIP to talk to the ASP/IIS box and visa versa.<BR><BR>When I use the following:<BR>---------------------------------------------------<BR><BR>&#060;%@ Language=VBScript %&#062;<BR>&#060;HTML&#062;<BR>&#060;HEAD&#062;<BR >&#060;META NAME="GENERATOR" Content="Microsoft Visual Studio 6.0"&#062;<BR><BR><BR>&#060;/HEAD&#062;<BR><BR>&#060;%<BR><BR>dim conn ,mrs,sqlstr,mcode,mdesc<BR><BR>set conn=server.CreateObject ("adodb.connection")<BR>set mrs=server.CreateObject ("adodb.recordset")<BR><BR><BR>conn.Open "OurDataServiceName", "OurUSERID", "OurPWD"<BR><BR><BR><BR>sqlstr="select code1,descript from admin.business1 ;"<BR> sqlstr,conn<BR>if mrs.eof then<BR> msgbox "I am sorry, there is no business of that type"<BR> conn.close<BR>else<BR> set mcode=mrs("code1")<BR> set mdesc=mrs("descript")<BR>end if<BR><BR>%&#062;<BR>&#060;BODY&#062;<BR>---------------------------------------------------<BR><BR>I Get the following Error in ASP back:<BR>---------------------------------------------------<BR><BR>Microsoft OLE DB Provider for ODBC Drivers error &#039 80004005&#039 <BR><BR>Specified driver could not be loaded due to system error 5 (Oracle ODBC Driver). <BR><BR>/select1.asp, line 16<BR>---------------------------------------------------<BR><BR>I installed Oracle8i Net8 on IIS and I have tested the DSN and it works fine. Both in the ODBC tester and in the Net8 config utility. I am stumped!!!<BR><BR>Does anyone know why I can talk to our db using ODBC inside IIS but can&#039t send a query via ASP??<BR><BR>Is there something wrong with my ASP code???<BR><BR>HEEEEEEEEEEELLLLLLLLLLLLPPP!!!<BR>< BR>

  2. #2
    Mark Guest

    Default RE: Oracle 8i/NT and ASP/ NT

    Try this:<BR><BR>&#060;%<BR>dim conn ,mrs,sqlstr,mcode,mdesc<BR><BR>set conn = Server.CreateObject("adodb.connection")<BR>conn.Op en "OurDataServiceName", "OurUSERID", "OurPWD"<BR>&#039--Where0: OurDataServiceName is a System DSN, not an Oracle tnsname---<BR><BR>sqlstr="select code1,descript from admin.business1" &#039&#060;&#060;Verify SQL<BR><BR>Set mrs = conn.execute(sqlstr)<BR><BR>if mrs.eof then<BR> Response.Write "msgbox &#039I am sorry, there is no business of that type&#039"<BR>else<BR> mcode=mrs("code1")<BR> mdesc=mrs("descript")<BR>end if<BR><BR>&#039---Close objects-----<BR>mrs.Close<BR>Set mrs = NOTHING<BR><BR>conn.Close<BR>Set conn = NOTHING<BR>%&#062;<BR>

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts