Ultradev instance tutorial: 2.2 Connecting to the database using ODBC
Author:Eve Cole
Update Time:2009-05-30 18:35:07
Chapter 2: Setting up the database
Section 2, connecting to the database through ODBC
Dreamweaver Ultradev 4 establishes a connection to the database through a data source. Moreover, it is safer to use the data source as the database connection. Once the ASP source code is leaked, the security of the database can be guaranteed (database files should not be placed in the web directory). How to create a data source? Follow me^0^
1. Open the ODBC Data Source Manager panel. Open the Control Panel in Windows 2000, then open the management tools, and you will be able to see the data source (ODBC) item. For Windows 9x, you can see it directly in the Control Panel.
Double-click the icon to open the manager, and then select System DSN. Our data source is added here.
2. Add data source. Click the Add button to start creating the data source. In the next dialog box, select the driver of the data source. Since we are using a database created by Microsoft Access, we select Microsoft Access Driver (*.mdb) as the database driver, such as As shown in the figure.
Click the Finish button to display the dialog box shown below. You can fill in the data source name casually. In order to be simple and easy to remember, here we name it with userinfo (table name). Be careful not to conflict. It doesn't matter if you fill it in or not, it just describes the purpose of this database. Click the Select button to select your database file. Find the database we created in the previous section and select it, as shown in the figure.
After confirmation, a data source is created successfully, as shown in the figure.