Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- CREATE TABLE IF NOT EXISTS `question` (
- `id` int(11) NOT NULL,
- `message` longtext COLLATE utf8_unicode_ci NOT NULL,
- `emailaddress` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL,
- `employee_id` int(11) DEFAULT NULL,
- `created_at` datetime DEFAULT NULL,
- `modified_at` datetime DEFAULT NULL
- )ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
- CREATE TABLE IF NOT EXISTS `employee` (
- `id` int(11) NOT NULL,
- `firstname` varchar(255) COLLATE utf8_unicode_ci NOT NULL,
- `lastname` varchar(255) COLLATE utf8_unicode_ci NOT NULL,
- `company_id` int(11) NOT NULL
- )ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
- CREATE TABLE IF NOT EXISTS `company` (
- `id` int(11) NOT NULL,
- `company_name` varchar(255) COLLATE utf8_unicode_ci NOT NULL
- )ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
- CREATE TABLE IF NOT EXISTS `onetime_item` (
- `item_id` int(11) NOT NULL,
- `item_name` varchar(255) COLLATE utf8_unicode_ci NOT NULL,
- `item_amount` int(10) NOT NULL,
- `company_id` int(11) NOT NULL,
- `employee_id` int(11) NOT NULL,
- `date` date NOT NULL
- )ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
- INSERT INTO employee (id, firstname, lastname ,company_id) VALUES (1, 'John', 'Smith', 1);
- INSERT INTO company (id, company_name) VALUES (1, 'Test Company');
- INSERT INTO question (id, message, emailaddress, employee_id, created_at, modified_at) VALUES ('1', 'test 1', 'tes@test.com', 1, '2016-1-14', NULL), ('2', 'test 2', 'tes@testing.com', 1, '2016-1-15', NULL);
- INSERT INTO onetime_item (item_id, item_name, item_amount, company_id, employee_id) VALUES (1, 'Car', 1, 1, 1), (2, 'Trip to New York', 15, 1, 1);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement