The ASP code would something like this:

<%
    accessdb="nwind.mdb"
    myDSN="DRIVER={Microsoft Access Driver (*.mdb)};"
    myDSN=myDSN & "DBQ=" & server.mappath(accessdb)
    mySQL="select * from customers"

    call query2table(mySQL,myDSN)
%>

To make this work, you need to specify the driver, the path to the actual
database file, the path to the database server .. things like that.  All you
are doing is specifying the paths to where the files are, manually instead
of relying on the system's registry settings.  I've heard this saves time
and could really be helpful if your site has a lot of heavy database access
and a lot of databases.  Regardless, CF doesn't seem to like doing it any
way other than with a System DSN.  Go figure...

Anyways, I think I will just do what mherbene suggested and use DSNs and
generate them dynamically as needed.  If anyone gets bored though and wants
to try to figure out a CF variation of the ASP DSNless connection, I would
be grateful, because every little resource saving measure helps and,
besides, now I'm just plain curious as to if it can really be done. ;)

Todd Ashworth

----- Original Message -----
From: "Chris Evans" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, March 28, 2000 1:56 PM
Subject: RE: DSNless connections


> How would you do it in ASP?  If you're using ODBC to do the connections, I
> would guess you could do it in CF.
>
>
> Chris Evans
> [EMAIL PROTECTED]
> http://www.fuseware.com


------------------------------------------------------------------------------
Archives: http://www.eGroups.com/list/cf-talk
To Unsubscribe visit 
http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/cf_talk or send a 
message to [EMAIL PROTECTED] with 'unsubscribe' in the body.

Reply via email to