[thelist] Connection string issue

Taurus James taurus_james at yahoo.com
Fri Jan 12 20:54:49 CST 2007


Flavia,

You have to use the full file system path to the database: 

drive_letter\db\database1.mdb

instead of what you have:

www.site.com/db/database1.mdb

- Taurus




--- "Flavia Tarzwell (FayeC)" <ftarzwell at fayec.com> wrote:

> Hi,
> 
> A while ago I created a members area for a site where the
> company would 
> upload the manuals, notes, etc for their products and only
> registered 
> users could access the pages to download the notes.
> I am not an expert programmer but that was easy enough.
> The site was running for years and from time to time they
> would move to 
> another server and I needed to change the path to the
> database.
> They finally got to one server that allowed relative paths to
> be used 
> and so for the last 2 years the site had been using the
> following 
> connection string:
> Set Con = Server.CreateObject("ADODB.Connection")
> ConnectString= "Provider=Microsoft.Jet.OLEDB.4.0;" &_
>           "Data Source=" &
> Server.MapPath("..\db\database1.mdb") 
>          
> Con.Open ConnectString
> 
> Then last month they moved the site to a new box and now the
> site gets 
> an error:
> Error Type:
> Server object, ASP 0175 (0x80004005)
> The '..' characters are not allowed in the Path parameter for
> the 
> MapPath method.
> 
> I did use the full new path to the database 
> (/home/voicerec/public_html/aspnet_client - the full path to
> the db 
> would actually be www.site.com/db/database1.mdb while the
> pages using 
> the db are at the same level www.site.com/asp/page.asp) that
> was given 
> to me but when I do so I get another error:
> Error Type:
> ADODB.Connection.1 (0x80004005)
> SQLState: IM002 Native Error Code: 0 [DataDirect][ODBC lib]
> Data source 
> name not found and no default driver specified
> 
> I am at my wits end here. I have tried 3 other connection
> strings and 
> still no luck.
> I would really appreciate some help figuring this out.
> 
> If anybody has any advice or point me to some tutorial on ADO 
> connections I might find the answer.
> 
> Thank you in advance for any help,
> 
> FayeC
> 
> 
> -- 
> 
> * * Please support the community that supports you.  * *
> http://evolt.org/help_support_evolt/
> 
> For unsubscribe and other options, including the Tip Harvester
> 
> and archives of thelist go to: http://lists.evolt.org 
> Workers of the Web, evolt ! 
> 



 
____________________________________________________________________________________
TV dinner still cooling? 
Check out "Tonight's Picks" on Yahoo! TV.
http://tv.yahoo.com/



More information about the thelist mailing list