Setup Microsoft Access Database on Windows Hosting using Plesk

To use a Microsoft Access Database (.mdf file), you will need to create a folder in your web space (inside the httpdocs folder) and give this folder full write permissions using the file manager in your Plesk control panel (click the padlock icon next to the folder you have created to set the permissions).

Hint: If you do not set write permissions, the database can not be written to and can not generate a temp file (in the same folder as your database) required for your access database to function correctly.

Once the database has been uploaded, you may wish to setup an ODBC connection to the database for easier connection.

Click the ODBC icon in your Plesk control panel for the domain. Next, click "Add New ODBC DNS". Give the connection a name. Select the driver as "Microsoft Access Database (.mdf)" and click ok. In the field [DBQ] DB File Path *, enter the server path to your database file you have uploaded to your web space e.g. C:\Inetpub\vhosts\yourdomain.com\httpdocs\folderyourcreated\database.mdf - Replace 'yourdomain.com' with your domain name. Replace 'folderyourcreated', with the folder you created in step 1. Replace 'database.mdf' with the name of your database file.

Leave all the other settings as default. Next, click test connection. It connect is successful, then click next and then ok. If the connection is unsuccessful, please ensure the server path to the database is correct.

If you want to connect to the database using your scripts, you can use:

strConnString = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=C:\Inetpub\vhosts\yourdomain.com\httpdocs\folderyourcreated\database.mdf" '## MS Access 2000

Note:The back slash '\' should be included in the path.
Also check for the database path where have you stored it and give the same path in the connection string.

Here are some use full links which you can go through while setting a Database Connection.

http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vbcon/html/vbtskCreatingConnectionToAccessDatabase.asp

http://www.basic-ultradev.com/articles/ADOConnections

  • 0 Users Found This Useful
Was this answer helpful?

Related Articles

How to increase your quota - Windows

On your Home page, click the domain name you need. Click Limits. Adjust the disk space. (And...

How to password protect a folder - Windows

To password protect a directory in your site and to specify authorized users: On your Home...

How to schedule backups - Windows

To schedule backup of your domain (web site): Click Backup in the Tools group. Click...

How to change SMTP port number - Windows

To set up Microsoft Outlook Express: Open Microsoft Outlook Express Go to Tools >...

How to customize web server error pages - Windows

To configure Plesk's web server to show your custom error pages: Switch on support for...