/* $Id: sqsdmbld.sql,v 1.1 1998/03/26 22:01:08 yxia Exp $		*/
/* $Log: sqsdmbld.sql,v $
# Revision 1.1  1998/03/26  22:01:08  yxia
# Initial revision
#
# Revision 1.1  1997/09/03  21:53:40  bgutierr
# Initial revision
#
# Revision 1.4  1997/07/09  23:42:16  aclarke
# log: OCA 2.0.2.11.0 files.
#
# Revision 1.1  1996/02/06  18:06:10  kmuniasa
# log: Initial version for d2 1.3 release.
#	*/
/* Copyright (c) 1993 by the Oracle Corporation */

/* -------------------------------------------------------------------- */
/* NAME         SQSDMBLD.SQL - SQL script to create demo tables under     */
/*              MS SQL Server database.                                 */
/*                                                                      */
/* NOTES        This file uses native datatypes to create table         */
/*              definition. It is database specific and thus is not     */
/*              portable. Use DEMODATA.SQL  to insert data  		*/
/*                                                                      */
/* OWNER        H THIO                                                  */
/*                                                                      */
/* MODIFIED                                                             */
/*   cbarrow	12/09/96 - Added Primary Key constraints 
/*   hthio      11/02/93 - Created                                      */
/* -------------------------------------------------------------------- */

SPOOL SQSDMBLD.LOG


DROP table DEPT;
DROP table EMP;

/* For SQL Server 4.2 please remove the constraint clauses */

CREATE TABLE DEPT (
   DEPTNO smallint NOT NULL,
   DNAME varchar (  14 )  NULL,
   LOC varchar (  13 )  NULL,
   Constraint pk_dept PRIMARY KEY (deptno)
 ) ;
CREATE TABLE EMP (
   EMPNO smallint NOT NULL,
   ENAME varchar (  10 )  NULL,
   JOB varchar (  9 )  NULL,
   MGR smallint NULL,
   HIREDATE datetime NULL,
   SAL float NULL,
   COMM float NULL,
   DEPTNO smallint NOT NULL,
   Constraint pk_emp PRIMARY KEY (deptno, empno)
 ) ;


SPOOL OFF
