I. Configure environment variables:
Softe Version:tomcat5.0.12/mysql4.1.7/mysql_driver---
Mysql-connector-java-3.1.4-beta-bin.jar
MySQL driver can be downloaded from www.mysql.com official website
Path:
Tomcat5 in D:\MYWEB\TOMCAT5;
MySQL in C:\Program files\mysql\mysql Server 4.1
Path (plus on the original basis):
D:\myweb\tomcat5\bin;d:\myweb\jdk1.4;d:\myweb\
Jdk1.4\bin;
D:\myweb\tomcat5\common\lib\servlet-api.jar; C:\Program files\
Mysql\mysql Server4.1\bin
Classpath:d:\myweb\tomcat5\common\lib\servlet-api.jar;d:\myweb\tomcat5\common\lib\jsp-api.jar
java_home:d:\myweb\jdk1.4
Catalina_home:d:\myweb\tomcat5
Second, the establishment of test database
Build a Forumdb database in MySQL, and create a table member as follows:
Create Database Forumdb;
CREATE TABLE Member
(
ID int,
Name varchar (6)
);
Then insert two test data as follows:
Insert INTO member values (1, "Zhang");
Insert into member values (2, "Wang");
At this point, the database is ready to complete.