List:General Discussion« Previous MessageNext Message »
From:Christopher R. Jones Date:May 4 2000 8:06pm
Subject:Re: Can I use MYSQL together with ASP?
View as plain text  
I have used MyODBC and ASP.  I use Visual Interdev to create the DSN 
statement.  For example:

<%@ LANGUAGE=JScript %>
<META NAME="GENERATOR" Content="Microsoft Visual Studio 6.0">


ConnectionString1a = "DSN=NT2Buildings;User 

conn1 = Server.CreateObject('ADODB.Connection');
conn1.Open( ConnectionString1a );
sql = "SELECT DISTINCT bldgtype, tpl FROM projects ORDER BY bldgtype";
rs1 = Server.CreateObject("ADODB.Recordset");
rs1.Open( sql, conn1);
arr1 = rs1.GetRows();
numrecords = arr1.ubound(2)+1;

Response.Write( "<h1>" + "NumRec: " + numrecords + "</h1>" );
var i;
for( i=0; i<numrecords; i++ )
         bldg = rs1('bldgtype');
         tpl = rs1('tpl');
         Response.Write( "<h1>" + bldg + "&nbsp;" + tpl + "</h1>" );

>Can someone please tell me if I can use the ASP (Active Server Pages or 
>VBScrift) to connect to my database from MYSQL? I've also downloaded 
>MYSQL-ODBC, but I don't know how to manage them.
>Please help me out of this problem.
>I've used MS-SQL 7.0 before, and here is the code I use to connect to 
>MS-SQL 7.0 databases.
>For example:
>Set db=CreateObject("ADODB.RecordSet")
>sqlstr = "SELECT FROM * person"
>db.Open sqlstr, DSN
>Please help!!
>Victor Dieu

Christopher R. Jones, P.Eng.
14 Oneida Avenue
Toronto, Ontario M5J 2E3
Tel. 416 203-7465
Fax. 416 203-3044
Email cj@stripped

Can I use MYSQL together with ASP?Victor Dieu4 May
  • Re: Can I use MYSQL together with ASP?Christopher R. Jones5 May