1
0
mirror of synced 2025-01-18 06:21:40 +03:00

code type is sql

This commit is contained in:
jackbravo 2007-09-06 16:13:18 +00:00
parent 1db6dfa30b
commit fb5a7395e5

View File

@ -71,7 +71,7 @@ Doctrine::exportSchema('models');
This would execute the following queries on mysql. This would execute the following queries on mysql.
<code> <code type="sql">
CREATE TABLE user (id BIGINT AUTO_INCREMENT, name VARCHAR(20), PRIMARY KEY(id), INDEX(id)); CREATE TABLE user (id BIGINT AUTO_INCREMENT, name VARCHAR(20), PRIMARY KEY(id), INDEX(id));
CREATE TABLE phonenumber (id INT AUTO_INCREMENT, phonenumber VARCHAR(20), user_id BIGINT, PRIMARY KEY(id), INDEX(user_id)); CREATE TABLE phonenumber (id INT AUTO_INCREMENT, phonenumber VARCHAR(20), user_id BIGINT, PRIMARY KEY(id), INDEX(user_id));
ALTER TABLE phonenumber ADD CONSTRAINT FOREIGN KEY (user_id) REFERENCES user(id) ON DELETE CASCADE; ALTER TABLE phonenumber ADD CONSTRAINT FOREIGN KEY (user_id) REFERENCES user(id) ON DELETE CASCADE;