Wrox Programmer Forums
| Search | Today's Posts | Mark Forums Read
Classic ASP Databases Discuss using ASP 3 to work with data in databases, including ASP Database Setup issues from the old P2P forum on this specific subtopic. See also the book forum Beginning ASP.NET Databases for questions specific to that book. NOT for ASP.NET 1.0, 1.1, or 2.0.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Classic ASP Databases section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
Old June 3rd, 2003, 11:48 PM
Registered User
Join Date: Jun 2003
Location: Mumbai, Maharastra, India.
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default Connect Database

Please inform me how do I connect a myserv database on server ?

What is syntax ?

If dsn is vikas then what will be the syntax ?

With regards
Vikas AThavale

Vikas Athavale
Mobile 91 9821461975
Old June 4th, 2003, 03:53 AM
Registered User
Join Date: Jun 2003
Location: , , Belgium.
Posts: 7
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via MSN to c_capo

Set con = Server.CreateObject("ADODB.Connection");
strCon = "dsn=vikas"

:: soulcreation.com ::
Old June 5th, 2003, 10:55 AM
Registered User
Join Date: Jun 2003
Location: , , .
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via AIM to shivanisaini Send a message via MSN to shivanisaini Send a message via Yahoo to shivanisaini

Hey guys..I am kinda new to this ASP Stuff, and can't figure out the solution to an error that I am getting..Here's the error:

Error Type:
Microsoft OLE DB Provider for ODBC Drivers (0x80004005)
[Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified
/shivani/cosmicswap/Clssfd.asp, line 6

And here's the code that I have on line 6 on this clssfd.asp page:

Set objConn = Server.CreateObject("ADODB.Connection")
objConn.Open"DRIVER= {Microsoft Access Driver(*.mdb)};DBQ=URL=fpdb/CosmicSwap.mdb"

Could anyone help me
Email me or post your answer here.


Old June 5th, 2003, 09:02 PM
Friend of Wrox
Join Date: Jun 2003
Location: Sydney, NSW, Australia.
Posts: 111
Thanks: 0
Thanked 0 Times in 0 Posts

It should be:

DBQ=" & Server.Mappath("/fpdb/ComsmicSwap.mdb")

(assuming that the fpdb directory is off the root of your website. The Server.Mappath() function returns the physical path of the supplied virtual path.

Similar Threads
Thread Thread Starter Forum Replies Last Post
how to connect database madu Java GUI 1 December 3rd, 2007 11:54 PM
How to connect SQL Database eapsokha Classic ASP Professional 1 March 10th, 2004 04:18 AM
Connect to remote database sankar Pro VB Databases 0 July 31st, 2003 01:43 AM
can't connect to database asprookie Classic ASP Databases 1 July 22nd, 2003 10:11 AM

Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.