Home > Database > Mysql Tutorial > 通过JDBC链接Mysql数据库_MySQL

通过JDBC链接Mysql数据库_MySQL

WBOY
Release: 2016-06-01 13:07:54
Original
973 people have browsed it

1、创建动态Web项目,将Mysql数据库的驱动包mysql-connector-java-5.1.25-bin.jar

添加至项目的构建路径中,放在WEB-INF->lib下


2、创建程序中的主页index.jsp

在其中加载数据库驱动并创建数据库链接

<meta http-equiv="Content-Type" content="text/html; charset=GB18030"><title>杩炴帴MySQL鏁版嵁搴</title>
Copy after login
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template