ASP Server not able to connect to ODBC data source

Question:

Whenever I try to connect to a Web Project that I have built (mostly with the Visual InterDev wizards) and I try to run the page in a browser I get the following dialog:

“[Microsoft][ODBCR Driver Manager]Data source name not found and no default driver specified”

The script debugger stops at the line:

DataConnArchiveFiles.Open Session(“DataConnArchiveFiles_ConnectionString”), Session(“DataConnArchiveFiles_RuntimeUserName”), Session(“DataConnArchiveFiles_RuntimePassword”)

I used the data connection build to create the data connection, and I have tried to use a System data source as well as a file data source, but all obtain the same error message.

The environment is Windows NT Server, with full install of the NT Server Options pack, and Visual InterDev 1.0 patched to Visual Studio Patch 3.

Being new to ASP environment and programming (although I understand VBScript pretty well, as I have done lots of VB 5.0 developing), I’m confused at what to do. I have searched the Microsoft Knowledgebase, and found nothing that has worked.

Thanks,
Erik

Answer:

Check that your global.asa file is executing. A common problem is that the Web in question is not marked as an application in IIS4. Sometimes a global.asa is working, but not the one in your Web. Also, you might want to check that you don’t have duplicate data source names. This can happen if you are using a file DSN and system DSN.

One sure-fire workaround is to hardcode the connection string in one of your ASP files. That way, you won’t be depending on the global.asa or the session variables to provide your connection string.

Share the Post:
Share on facebook
Share on twitter
Share on linkedin

Overview

The Latest

microsoft careers

Top Careers at Microsoft

Microsoft has gained its position as one of the top companies in the world, and Microsoft careers are flourishing. This multinational company is efficiently developing popular software and computers with other consumer electronics. It is a dream come true for so many people to acquire a high paid, high-prestige job

your company's audio

4 Areas of Your Company Where Your Audio Really Matters

Your company probably relies on audio more than you realize. Whether you’re creating a spoken text message to a colleague or giving a speech, you want your audio to shine. Otherwise, you could cause avoidable friction points and potentially hurt your brand reputation. For example, let’s say you create a

chrome os developer mode

How to Turn on Chrome OS Developer Mode

Google’s Chrome OS is a popular operating system that is widely used on Chromebooks and other devices. While it is designed to be simple and user-friendly, there are times when users may want to access additional features and functionality. One way to do this is by turning on Chrome OS