Commit 4fe42651 by Trevor Austin

Add create combined table migration

parent d39f4929
-- create table posts (
-- id INT AUTO_INCREMENT PRIMARY KEY,
-- slug VARCHAR(30) NOT NULL,
-- title VARCHAR(255) NOT NULL,
-- body TEXT
-- );
--
-- create table comments (
-- id INT AUTO_INCREMENT PRIMARY KEY,
-- post_id INT,
-- body TEXT,
-- author VARCHAR(30),
-- FOREIGN KEY(post_id) REFERENCES posts(id)
-- );
create table posts_and_comments (
id INT AUTO_INCREMENT PRIMARY KEY,
body TEXT,
slug VARCHAR(30) NOT NULL,
title VARCHAR(255) NOT NULL,
post_id INT,
author VARCHAR(30)
)
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment