diff options
author | David Heinemeier Hansson <david@loudthinking.com> | 2005-04-18 07:52:58 +0000 |
---|---|---|
committer | David Heinemeier Hansson <david@loudthinking.com> | 2005-04-18 07:52:58 +0000 |
commit | 03097d3a6047e269641a14f4c93838598011f0b5 (patch) | |
tree | a30a49108dfffc631ee4eb652fce7b41bb4b517e /activerecord/test/fixtures/db_definitions/sqlite.sql | |
parent | b8c07c0325fdfee701de1a68811c941bced606be (diff) | |
download | rails-03097d3a6047e269641a14f4c93838598011f0b5.tar.gz rails-03097d3a6047e269641a14f4c93838598011f0b5.tar.bz2 rails-03097d3a6047e269641a14f4c93838598011f0b5.zip |
Fixed that fixtures were being deleted in the same order as inserts causing FK errors #890 [andrew.john.peters@gmail.com]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1205 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
Diffstat (limited to 'activerecord/test/fixtures/db_definitions/sqlite.sql')
-rw-r--r-- | activerecord/test/fixtures/db_definitions/sqlite.sql | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/activerecord/test/fixtures/db_definitions/sqlite.sql b/activerecord/test/fixtures/db_definitions/sqlite.sql index 33c85b4d1c..4507e2c4b2 100644 --- a/activerecord/test/fixtures/db_definitions/sqlite.sql +++ b/activerecord/test/fixtures/db_definitions/sqlite.sql @@ -151,3 +151,14 @@ CREATE TABLE 'categories_posts' ( 'category_id' INTEGER NOT NULL, 'post_id' INTEGER NOT NULL ); + +CREATE TABLE 'fk_test_has_pk' ( + 'id' INTEGER NOT NULL PRIMARY KEY +); + +CREATE TABLE 'fk_test_has_fk' ( + 'id' INTEGER NOT NULL PRIMARY KEY, + 'fk_id' INTEGER NOT NULL, + + FOREIGN KEY ('fk_id') REFERENCES 'fk_test_has_pk'('id') +); |