spring的源代码

源代码在线查看: initdb.txt

软件大小: 17633 K
上传用户: caim3587
关键词: spring 源代码
下载地址: 免注册下载 普通下载 VIP

相关代码

				CREATE DATABASE petclinic;
				
				GRANT ALL ON petclinic.* TO pc@localhost IDENTIFIED BY 'pc';
				
				USE petclinic;
				
				CREATE TABLE vets (
				  id INT(4) UNSIGNED NOT NULL AUTO_INCREMENT PRIMARY KEY,
				  first_name VARCHAR(30),
				  last_name VARCHAR(30),
				  INDEX(last_name)
				);
				
				CREATE TABLE specialties (
				  id INT(4) UNSIGNED NOT NULL AUTO_INCREMENT PRIMARY KEY,
				  name VARCHAR(80),
				  INDEX(name)
				);
				
				CREATE TABLE vet_specialties (
				  vet_id INT(4) UNSIGNED NOT NULL REFERENCES vet(id),
				  specialty_id INT(4) UNSIGNED NOT NULL REFERENCES specialties(id)
				);
				
				CREATE TABLE types (
				  id INT(4) UNSIGNED NOT NULL AUTO_INCREMENT PRIMARY KEY,
				  name VARCHAR(80),
				  INDEX(name)
				);
				
				CREATE TABLE owners (
				  id INT(4) UNSIGNED NOT NULL AUTO_INCREMENT PRIMARY KEY,
				  first_name VARCHAR(30),
				  last_name VARCHAR(30),
				  address VARCHAR(255),
				  city VARCHAR(80),
				  telephone VARCHAR(20),
				  INDEX(last_name)
				);
				
				CREATE TABLE pets (
				  id INT(4) UNSIGNED NOT NULL AUTO_INCREMENT PRIMARY KEY,
				  name VARCHAR(30),
				  birth_date DATE,
				  type_id INT(4) UNSIGNED NOT NULL REFERENCES types(id),
				  owner_id INT(4) UNSIGNED NOT NULL REFERENCES owner(id),
				  INDEX(name)
				);
				
				CREATE TABLE visits (
				  id INT(4) UNSIGNED NOT NULL AUTO_INCREMENT PRIMARY KEY,
				  pet_id INT(4) UNSIGNED NOT NULL REFERENCES pets(id),
				  visit_date DATE,
				  description VARCHAR(255),
				  INDEX(pet_id)
				);
							

相关资源