Skip to content

Commit

Permalink
Merge pull request #743 from jfcabral/bugfix/db2-tests1
Browse files Browse the repository at this point in the history
Tests@DB2 - Fix db2_schema.sql
  • Loading branch information
Igor Polevoy committed Jul 9, 2018
2 parents 4113afe + 8a2bb24 commit bf72b9c
Showing 1 changed file with 4 additions and 6 deletions.
10 changes: 4 additions & 6 deletions activejdbc/src/test/resources/db2_schema.sql
@@ -1,4 +1,3 @@

CALL dropTable('people');
CREATE TABLE people (id int primary key GENERATED ALWAYS AS IDENTITY, name VARCHAR(56) NOT NULL, last_name VARCHAR(56), dob DATE, graduation_date DATE, created_at TIMESTAMP, updated_at TIMESTAMP);

Expand Down Expand Up @@ -207,11 +206,10 @@ CALL dropTable('musicians');
CREATE TABLE musicians (musician_id int primary key GENERATED ALWAYS AS IDENTITY, first_name VARCHAR(56) NOT NULL, last_name VARCHAR(56) NOT NULL);

CALL dropTable('bands_genres');
CREATE TABLE bands_genres (the_id int primary key GENERATED ALWAYS AS IDENTITY, band_id int, genre_id);
CREATE TABLE bands_genres (the_id int primary key GENERATED ALWAYS AS IDENTITY, band_id int, genre_id int);

CALL dropTable('bands_musicians');
CREATE TABLE bands_musicians (the_id int primary key GENERATED ALWAYS AS IDENTITY, band_id int, musician_id);

CREATE TABLE bands_musicians (the_id int primary key GENERATED ALWAYS AS IDENTITY, band_id int, musician_id int);

DROP TABLE IF EXISTS employees;
CREATE TABLE employees ( id int primary key GENERATED ALWAYS AS IDENTITY, first_name VARCHAR(56) NOT NULL, last_name VARCHAR(56), position VARCHAR(56), active INT, department VARCHAR(56), created_at TIMESTAMP, updated_at TIMESTAMP);
CALL dropTable('employees');
CREATE TABLE employees (id int primary key GENERATED ALWAYS AS IDENTITY, first_name VARCHAR(56) NOT NULL, last_name VARCHAR(56), position VARCHAR(56), active INT, department VARCHAR(56), created_at TIMESTAMP, updated_at TIMESTAMP);

0 comments on commit bf72b9c

Please sign in to comment.