Mike,


I agree.

See my example below.

Very Best R:egards,

Razzak.


At 09:27 AM 10/2/2003 -0500, Mike Byerley you wrote:


In ANY instance, the DSN-less connection is preferred.


----- Original Message -----
From: "A. Razzak Memon" <[EMAIL PROTECTED]>
To: "RBASE-L Mailing List" <[EMAIL PROTECTED]>
Sent: Thursday, October 02, 2003 6:14 AM
Subject: [RBASE-L] - Re: IIS and R:Base - Razzak's Reply

> At 10:29 AM 10/2/2003 +0200, Roberto Zanotti wrote:
>
> >I have to query an R:Base database with some asp page and Microsoft IIS on
> >an XP pc.
> >I have prepared a data source with the R:BASE Database Driver, but when i
> >try to
> >open the database with my asp pages, i hear a BEEP and then IIS seems to
> >be freezed.
> >
> >Any Ideas ?
>
> Roberto,
>
> 01. Make sure that you have defined a System DSN
>
> 02. However, try the following example using "DSN Less
> Connection" method via Oterro ODBC Driver for ASP pages.
>
> If you need the complete demo and all files, let me know.
>
> <%@ LANGUAGE=JSCRIPT %>
> <!--#include file="adojavas.inc"-->
> <script language=VBScript runat=server>
> On Error Resume Next
> Dim e, vnum
> Session("vQuit") = 0
> ' Create a Connection object
> Set Session("Connect") = Server.CreateObject("ADODB.Connection")
> Session("Connect").Errors.Clear
> Err.Clear
> ' Connect to an R:BASE database through ODBC
> ' Session("Connect").Open "Concomp"
> ' For a connection without a predefined DSN
> ' Save this string for later reuse
> Session("ConcompCS") = "Driver=Oterro Database Driver
> (*.rb1);DBQ=C:\RBTI\RBWin65\SAMPLES\CONCOMP\CONCOMP.RB1"
> Session("Connect").Open Session("ConcompCS")
> For e = 0 To Session("Connect").Errors.Count - 1
> vnum = Session("Connect").Errors(e).Number
> If vnum < 0 Then
> Response.Write "Sorry, the database is not available at
> this time.<br>"
> Response.Write "error number is:" +
> Session("Connect").Errors(e).Number + "<br>"
> Response.Write "error description is:" +
> Session("Connect").Errors(e).Description + "<br>"
> vQuit = 1
> End If
> Next
> </script>
> <%
> if (Session("vQuit") != 0) {
> Response.Write("Try again at another time<br>");
> } else {
> // Show real starting page
> var rsADO, qstr;
> %>
> <html>
> <head>
> <title>RBASE Concomp Test Page</title>
> </head>
> <body bgColor="silver">
> <h1>
> R:BASE Sample Web Page Using ASP<br>
> </h1>
> <form method="post" action="Sample_Select.asp">
> <h3>Choose a table: <select name="TabName" size="1">
> <%
> // Display a select list with the table names
> qstr = "SELECT sys_table_name from sys_tables where sys_table_type
> ne 'system table' order by sys_table_name";
> Session("Connect").CommandTimeout = 120;
> rsADO = Session("Connect").Execute(qstr);
> while (!rsADO.EOF) {
> %><option
> value="<%=rsADO("sys_table_name")%>"><%=rsADO("sys_table_name")%></option><%
> rsADO.MoveNext();
> }
> %>
> </select>
> <input type="submit" name="Submit" value="See the data"></h3>
> </form>
> </body>
> </html>
> <%
> }
> %>
>
> Have Fun!
>
> Very Best R:egards,
>
> Razzak.



Reply via email to