From daf3e92a316c041b6b2bf331c8d2a51e710fe7bf Mon Sep 17 00:00:00 2001
From: David Heinemeier Hansson <david@loudthinking.com>
Date: Sat, 1 Jan 2005 19:22:16 +0000
Subject: Added a db2 adapter that only depends on the Ruby/DB2 bindings
 (http://raa.ruby-lang.org/project/ruby-db2/) #386 [Maik Schmidt]. Converted
 all the fixtures to YAML style ones.

git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@303 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
---
 activerecord/test/fixtures/db_definitions/db2.sql | 112 ++++++++++++++++++++++
 1 file changed, 112 insertions(+)
 create mode 100644 activerecord/test/fixtures/db_definitions/db2.sql

(limited to 'activerecord/test/fixtures/db_definitions/db2.sql')

diff --git a/activerecord/test/fixtures/db_definitions/db2.sql b/activerecord/test/fixtures/db_definitions/db2.sql
new file mode 100644
index 0000000000..7171bd3e16
--- /dev/null
+++ b/activerecord/test/fixtures/db_definitions/db2.sql
@@ -0,0 +1,112 @@
+CREATE TABLE accounts (
+  id int generated by default as identity (start with +10000),
+  firm_id int default NULL,
+  credit_limit int default NULL,
+  PRIMARY KEY (id)
+);
+
+CREATE TABLE companies (
+  id int generated by default as identity (start with +10000),
+  type varchar(50) default NULL,
+  ruby_type varchar(50) default NULL,
+  firm_id int default NULL,
+  name varchar(50) default NULL,
+  client_of int default NULL,
+  rating int default 1,
+  PRIMARY KEY (id)
+);
+
+CREATE TABLE topics (
+  id int generated by default as identity (start with +10000),
+  title varchar(255) default NULL,
+  author_name varchar(255) default NULL,
+  author_email_address varchar(255) default NULL,
+  written_on timestamp default NULL,
+  bonus_time time default NULL,
+  last_read date default NULL,
+  content varchar(3000),
+  approved smallint default 1,
+  replies_count int default 0,
+  parent_id int default NULL,
+  type varchar(50) default NULL,
+  PRIMARY KEY (id)
+);
+
+CREATE TABLE developers (
+  id int generated by default as identity (start with +10000),
+  name varchar(100) default NULL,
+  salary int default 70000,
+  PRIMARY KEY (id)
+);
+
+CREATE TABLE projects (
+  id int generated by default as identity (start with +10000),
+  name varchar(100) default NULL,
+  PRIMARY KEY (id)
+);
+
+CREATE TABLE developers_projects (
+  developer_id int NOT NULL,
+  project_id int NOT NULL,
+  joined_on date default NULL
+);
+
+CREATE TABLE customers (
+  id int generated by default as identity (start with +10000),
+  name varchar(100) default NULL,
+  balance int default 0,
+  address_street varchar(100) default NULL,
+  address_city varchar(100) default NULL,
+  address_country varchar(100) default NULL,
+  PRIMARY KEY (id)
+);
+
+CREATE TABLE movies (
+  movieid int generated by default as identity (start with +10000),
+  name varchar(100) default NULL,
+  PRIMARY KEY (movieid)
+);
+
+CREATE TABLE subscribers (
+  nick varchar(100) NOT NULL,
+  name varchar(100) default NULL,
+  PRIMARY KEY (nick)
+);
+
+CREATE TABLE booleantests (
+  id int generated by default as identity (start with +10000),
+  value int default NULL,
+  PRIMARY KEY (id)
+);
+
+CREATE TABLE auto_id_tests (
+  auto_id int generated by default as identity (start with +10000),
+  value int default NULL,
+  PRIMARY KEY (auto_id)
+);
+
+CREATE TABLE entrants (
+  id int NOT NULL PRIMARY KEY,
+  name varchar(255) NOT NULL,
+  course_id int NOT NULL
+);
+
+CREATE TABLE colnametests (
+  id int generated by default as identity (start with +10000),
+  references int NOT NULL,
+  PRIMARY KEY (id)
+);
+
+CREATE TABLE mixins (
+  id int generated by default as identity (start with +10000),
+  parent_id int default NULL,
+  pos int default NULL,
+  created_at timestamp default NULL,
+  updated_at timestamp default NULL,
+  lft int default NULL,
+  rgt int default NULL,
+  root_id int default NULL,
+  type varchar(40) default NULL,
+  PRIMARY KEY (id)
+);
+
-- 
cgit v1.2.3

