Discussion Locked

SQL + Interdev

0 helpful
7 replies
Closed to new repliesThis discussion is closed. It stays readable, but it takes no new replies.

I'm working on a basic data entry page in Interdev that stores its data into SQL Server 2K. Everything works great locally, however when I publish the page online and access the page it requires that I log onto SQL in order to save the page. This page will be available for new prospects which means I'll have to have the page available to all anonymous users, I know theres a way to do this, just clueless on where to start. Any help would be appreciative.

Michael

7 replies

by andrew

There are a lot of ways to do this, but we need a little more info.

Are you using COM objects to encapsulate the data access? This is the most robust way.

Are you using ADO directly from ASP?

Are you using NT Authentication or SQL Authentication?

All these things boil down to the connection method and credentials used to access the DB.

For example if your using ADO from ASP, you might use the following:

Dim oCon
Set oCon = Server.CreateObject("ADODB.Connection")
oCon.Open "Provider=SQLOLEDB.1;Password="sa_password";User ID=sa;Initial Catalog=database_name;Data Source=database_server

This will open a db connection using SQLOLEDB with SQL authentication.

In your dev environment, you're probably using NT Authentication (you are the user) when in your production environment your application will actually be the user to the db.

by sergey kovzik

to simplify your life you can create system or file level DSN (optionally with autorization information in it) and open it from your ASP-pages. Alternatively you can provide direct access to SQL from Web-Server account, you'll need to create IWAM_COMPUTERNAME account in your SQL database with some password, but you'll need to change password for this account on Web-Server itself too. Better to create DSN.

by andrew

Be advised that using a DSN will impose an extra layer (the ODBC driver) that you'll have to call through to get to the database. Pure SQLOLEDB is faster.

You do not have to create an IWAM_MachineName account in SQL Server, because you will supply the user name and password you wish to use in the connection string.

This discussion is closed to new replies.