Đang chuẩn bị liên kết để tải về tài liệu:
Hibernate Tutorial 01

Không đóng trình duyệt đến khi xuất hiện nút TẢI XUỐNG

Hibernate Tutorial 01 Object/Relational Mapping | Hibernate Tutorial 01 Object Relational Mapping By Gary Mak hibernatetutorials@metaarchit.com September 2006 1. Installation 1.1. Installing JDK JDK is an essential toolkit provided for Java application development. You can go to http java.sun.com j2se 1.5.0 download.jsp to download JDK 5.0. Install it into a folder say C jdk1.5.0 . 1.2. Installing Eclipse Web Tools Platform WTP Eclipse is an IDE for developing Java application. WTP provides some tools for Web and J2EE development such as XML editor and SQL editor. You can go to http www.eclipse.org webtools and download WTP All-in-one 1.0. Unzip it into a folder say C eclipse . 1.3. Installing HSQLDB HSQLDB is an open source SQL relational database engine written in Java. You can go to http www.hsqldb.org and download HSQLDB 1.8.0. Unzip it into a folder say C hsqldb . 1.4. Installing DbVisualizer DbVisualizer is a Java-based visual database development tool. You can go to http www.minq.se products dbvis download.html and download DbVisualizer 5.0 free version. Unzip it into a folder say C DbVisualizer-5.0 2. Setting up the database Suppose we need to develop an online bookshop application. It will use relational database to store its application data. 2.1. Creating a HSQLDB database instance To create a new HSQLDB database instance use the following command. Some files BookShopDB. will be created for the first time running this command. Page 1 of 8 java -cp lib hsqldb.jar org.hsqldb.Server -database.0 BookShopDB -dbname.0 BookShopDB Use DbVisualizer to connect this database using the following properties Driver JDBC HSQLDB Server Database URL jdbc hsqldb hsql localhost BookShopDB Userid sa Password empty 2.2. Creating the tables relational model For the first step we create the tables for our online bookshop using the following SQL statements CREATE TABLE PUBLISHER CODE PUBLISHER_NAME ADDRESS PRIMARY KEY CODE VARCHAR 4 VARCHAR 100 VARCHAR 200 NOT NOT NULL NULL CREATE TABLE BOOK ISBN VARCHAR 50 NOT NULL BOOK_NAME

TÀI LIỆU LIÊN QUAN
Đã phát hiện trình chặn quảng cáo AdBlock
Trang web này phụ thuộc vào doanh thu từ số lần hiển thị quảng cáo để tồn tại. Vui lòng tắt trình chặn quảng cáo của bạn hoặc tạm dừng tính năng chặn quảng cáo cho trang web này.