Accessing Database from Web Server

Accessing Database from Web Server


I have added a data connection in Visual Interdev. In the Data View I can see all my tables, fields and so on. My database resides on a SQL 7 server and my Web application is on the IIS 4 server. My problem is that I keep getting this error:

Microsoft OLE DB Provider for ODBC Drivers error '80040e4d' [Microsoft][ODBC SQL Server Driver][SQL Server]Login failed for user 'SMIWEBIUSR_SMIWEB'. /Test/Page2.asp, line 24 

I have this code on my ASP:

Set oRs=Server.CreateObject("ADODB.Connection")oRs.Open Application("Connection1_ConnectionString"),Application("Connection1_RuntimeUserName"),Application("Connection1_RuntimePassword")	oRs.Execute ("Select * From tblDetail&qout;)


This is one of the most common mistakes made by programmers.

When you are developing, you can see all the tables of a database because you have an ODBC DSN (Data Source Name) set up on your computer. This is set up so that Visual InterDev can see the database.

When your application is running from a Web Server Computer, it is looking for the YOUR computer's DSN on the Web Server Computer. When it does not find one, it fails. You need to set up the same DSN on the Web Server computer. Test the DSN when you have created it to make sure the database can be accessed succesfully.

Share the Post:
Heading photo, Metadata.

What is Metadata?

What is metadata? Well, It’s an odd concept to wrap your head around. Metadata is essentially the secondary layer of data that tracks details about the “regular” data. The regular

XDR solutions

The Benefits of Using XDR Solutions

Cybercriminals constantly adapt their strategies, developing newer, more powerful, and intelligent ways to attack your network. Since security professionals must innovate as well, more conventional endpoint detection solutions have evolved

AI is revolutionizing fraud detection

How AI is Revolutionizing Fraud Detection

Artificial intelligence – commonly known as AI – means a form of technology with multiple uses. As a result, it has become extremely valuable to a number of businesses across

AI innovation

Companies Leading AI Innovation in 2023

Artificial intelligence (AI) has been transforming industries and revolutionizing business operations. AI’s potential to enhance efficiency and productivity has become crucial to many businesses. As we move into 2023, several

data fivetran pricing

Fivetran Pricing Explained

One of the biggest trends of the 21st century is the massive surge in analytics. Analytics is the process of utilizing data to drive future decision-making. With so much of

kubernetes logging

Kubernetes Logging: What You Need to Know

Kubernetes from Google is one of the most popular open-source and free container management solutions made to make managing and deploying applications easier. It has a solid architecture that makes