-- ================================================================================
--   mysql SQL DDL Script File
-- ================================================================================


-- ===============================================================================
-- 
--   Generated by:      tedia2sql -- v1.2.12
--                      See http://tedia2sql.tigris.org/AUTHORS.html for tedia2sql author information
-- 
--   Target Database:   mysql
--   Generated at:      Thu Dec  6 01:55:55 2007
--   Input Files:       employee.dia
-- 
-- ================================================================================



-- Generated SQL Constraints Drop statements
-- --------------------------------------------------------------------
--     Target Database:   mysql
--     SQL Generator:     tedia2sql -- v1.2.12
--     Generated at:      Thu Dec  6 01:55:55 2007
--     Input Files:       employee.dia



-- Generated Permissions Drops
-- --------------------------------------------------------------------
--     Target Database:   mysql
--     SQL Generator:     tedia2sql -- v1.2.12
--     Generated at:      Thu Dec  6 01:55:55 2007
--     Input Files:       employee.dia




-- Generated SQL View Drop Statements
-- --------------------------------------------------------------------
--     Target Database:   mysql
--     SQL Generator:     tedia2sql -- v1.2.12
--     Generated at:      Thu Dec  6 01:55:55 2007
--     Input Files:       employee.dia



-- Generated SQL Schema Drop statements
-- --------------------------------------------------------------------
--     Target Database:   mysql
--     SQL Generator:     tedia2sql -- v1.2.12
--     Generated at:      Thu Dec  6 01:55:55 2007
--     Input Files:       employee.dia

 drop table if exists employee ;
 drop table if exists department ;


-- Generated SQL Schema
-- --------------------------------------------------------------------
--     Target Database:   mysql
--     SQL Generator:     tedia2sql -- v1.2.12
--     Generated at:      Thu Dec  6 01:55:55 2007
--     Input Files:       employee.dia


-- employee
create table employee (
  employee_id                int unsigned auto_increment not null,
  department_id             int not null,
  first_name                varchar(255) not null,
  last_name                 varchar(255),
  start_date                date,
  constraint pk_Employee primary key (employee_id)
) ;

-- department
create table department (
  department_id              int unsigned auto_increment not null,
  name                      varchar(255) not null,
  constraint pk_Department primary key (department_id)
) ;




-- Generated SQL Views
-- --------------------------------------------------------------------
--     Target Database:   mysql
--     SQL Generator:     tedia2sql -- v1.2.12
--     Generated at:      Thu Dec  6 01:55:55 2007
--     Input Files:       employee.dia




-- Generated Permissions
-- --------------------------------------------------------------------
--     Target Database:   mysql
--     SQL Generator:     tedia2sql -- v1.2.12
--     Generated at:      Thu Dec  6 01:55:55 2007
--     Input Files:       employee.dia



-- Generated SQL Insert statements
-- --------------------------------------------------------------------
--     Target Database:   mysql
--     SQL Generator:     tedia2sql -- v1.2.12
--     Generated at:      Thu Dec  6 01:55:55 2007
--     Input Files:       employee.dia


-- inserts for department (department_id,name)
insert into department (department_id,name) values ( 1,'Marketing' ) ;
insert into department (department_id,name) values ( 2,'Production' ) ;
insert into department (department_id,name) values ( 3,'Design' ) ;


-- Generated SQL Constraints
-- --------------------------------------------------------------------
--     Target Database:   mysql
--     SQL Generator:     tedia2sql -- v1.2.12
--     Generated at:      Thu Dec  6 01:55:55 2007
--     Input Files:       employee.dia


