composite_primary_keys 12.0.2 → 12.0.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/History.rdoc +880 -841
- data/README.rdoc +180 -179
- data/lib/composite_primary_keys/active_model/attribute_assignment.rb +19 -0
- data/lib/composite_primary_keys/arel/sqlserver.rb +1 -3
- data/lib/composite_primary_keys/associations/association_scope.rb +68 -68
- data/lib/composite_primary_keys/associations/join_dependency.rb +103 -103
- data/lib/composite_primary_keys/associations/through_association.rb +2 -1
- data/lib/composite_primary_keys/attribute_methods/primary_key.rb +13 -0
- data/lib/composite_primary_keys/attribute_methods/read.rb +30 -30
- data/lib/composite_primary_keys/attribute_methods/write.rb +35 -35
- data/lib/composite_primary_keys/attribute_methods.rb +9 -9
- data/lib/composite_primary_keys/base.rb +141 -130
- data/lib/composite_primary_keys/composite_arrays.rb +0 -8
- data/lib/composite_primary_keys/connection_adapters/abstract/database_statements.rb +37 -17
- data/lib/composite_primary_keys/connection_adapters/sqlserver/database_statements.rb +44 -23
- data/lib/composite_primary_keys/core.rb +48 -48
- data/lib/composite_primary_keys/persistence.rb +82 -81
- data/lib/composite_primary_keys/reflection.rb +29 -29
- data/lib/composite_primary_keys/relation/batches.rb +1 -1
- data/lib/composite_primary_keys/relation/calculations.rb +81 -81
- data/lib/composite_primary_keys/relation/finder_methods.rb +235 -235
- data/lib/composite_primary_keys/relation/predicate_builder/association_query_value.rb +20 -20
- data/lib/composite_primary_keys/relation/query_methods.rb +42 -42
- data/lib/composite_primary_keys/relation/where_clause.rb +23 -23
- data/lib/composite_primary_keys/relation.rb +193 -118
- data/lib/composite_primary_keys/version.rb +8 -8
- data/lib/composite_primary_keys.rb +117 -118
- data/test/abstract_unit.rb +114 -113
- data/test/connections/databases.ci.yml +22 -19
- data/test/fixtures/article.rb +4 -0
- data/test/fixtures/articles.yml +4 -3
- data/test/fixtures/comment.rb +1 -3
- data/test/fixtures/comments.yml +10 -9
- data/test/fixtures/db_definitions/db2-create-tables.sql +112 -126
- data/test/fixtures/db_definitions/db2-drop-tables.sql +17 -19
- data/test/fixtures/db_definitions/mysql.sql +180 -217
- data/test/fixtures/db_definitions/oracle.drop.sql +42 -48
- data/test/fixtures/db_definitions/oracle.sql +200 -236
- data/test/fixtures/db_definitions/postgresql.sql +183 -220
- data/test/fixtures/db_definitions/sqlite.sql +170 -206
- data/test/fixtures/db_definitions/sqlserver.sql +176 -212
- data/test/fixtures/department.rb +16 -11
- data/test/fixtures/departments.yml +15 -15
- data/test/fixtures/employees.yml +27 -27
- data/test/fixtures/readings.yml +2 -2
- data/test/fixtures/restaurants_suburbs.yml +11 -11
- data/test/fixtures/streets.yml +16 -16
- data/test/fixtures/suburbs.yml +14 -14
- data/test/fixtures/user.rb +11 -10
- data/test/test_associations.rb +358 -351
- data/test/test_attributes.rb +60 -60
- data/test/test_calculations.rb +42 -42
- data/test/test_create.rb +218 -183
- data/test/test_delete.rb +182 -179
- data/test/test_exists.rb +39 -39
- data/test/test_find.rb +164 -145
- data/test/test_habtm.rb +2 -2
- data/test/test_ids.rb +112 -116
- data/test/test_nested_attributes.rb +67 -124
- data/test/test_polymorphic.rb +29 -13
- data/test/test_preload.rb +4 -3
- data/test/test_serialize.rb +2 -2
- data/test/test_update.rb +96 -78
- metadata +4 -19
- data/test/fixtures/hack.rb +0 -5
- data/test/fixtures/hacks.yml +0 -3
- data/test/fixtures/pk_called_id.rb +0 -5
- data/test/fixtures/pk_called_ids.yml +0 -11
- data/test/fixtures/reference_code_using_composite_key_alias.rb +0 -8
- data/test/fixtures/reference_code_using_simple_key_alias.rb +0 -8
- data/test/fixtures/seat.rb +0 -5
- data/test/fixtures/seats.yml +0 -9
- data/test/fixtures/topic.rb +0 -6
- data/test/fixtures/topic_source.rb +0 -7
- data/test/test_aliases.rb +0 -18
- data/test/test_enum.rb +0 -21
- data/test/test_suite.rb +0 -35
data/test/abstract_unit.rb
CHANGED
@@ -1,113 +1,114 @@
|
|
1
|
-
spec_name = ENV['ADAPTER'] || 'sqlite'
|
2
|
-
require 'bundler
|
3
|
-
require 'minitest/autorun'
|
4
|
-
|
5
|
-
Bundler.
|
6
|
-
require
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
self.
|
31
|
-
self.
|
32
|
-
self.
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
#
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
@
|
71
|
-
@
|
72
|
-
|
73
|
-
|
74
|
-
|
75
|
-
|
76
|
-
|
77
|
-
|
78
|
-
|
79
|
-
|
80
|
-
|
81
|
-
|
82
|
-
|
83
|
-
|
84
|
-
|
85
|
-
|
86
|
-
|
87
|
-
|
88
|
-
|
89
|
-
|
90
|
-
|
91
|
-
|
92
|
-
|
93
|
-
|
94
|
-
|
95
|
-
|
96
|
-
|
97
|
-
end
|
98
|
-
|
99
|
-
|
100
|
-
|
101
|
-
|
102
|
-
|
103
|
-
|
104
|
-
|
105
|
-
|
106
|
-
|
107
|
-
|
108
|
-
|
109
|
-
|
110
|
-
|
111
|
-
end
|
112
|
-
|
113
|
-
|
1
|
+
spec_name = ENV['ADAPTER'] || 'sqlite'
|
2
|
+
require 'bundler'
|
3
|
+
require 'minitest/autorun'
|
4
|
+
|
5
|
+
Bundler.setup(:default, spec_name.to_sym)
|
6
|
+
Bundler.require(:default, spec_name.to_sym)
|
7
|
+
require 'composite_primary_keys'
|
8
|
+
|
9
|
+
# Require the connection spec
|
10
|
+
PROJECT_ROOT = File.expand_path(File.join(File.dirname(__FILE__), '..'))
|
11
|
+
require File.join(PROJECT_ROOT, 'test', 'connections', 'connection_spec')
|
12
|
+
|
13
|
+
spec = CompositePrimaryKeys::ConnectionSpec[spec_name]
|
14
|
+
puts "Loaded #{spec_name}"
|
15
|
+
|
16
|
+
# And now connect to the database
|
17
|
+
ActiveRecord::Base.establish_connection(spec)
|
18
|
+
|
19
|
+
# Tell active record about the configuration
|
20
|
+
ActiveRecord::Base.configurations = {test: spec}
|
21
|
+
|
22
|
+
# Tell ActiveRecord where to find models
|
23
|
+
ActiveSupport::Dependencies.autoload_paths << File.join(PROJECT_ROOT, 'test', 'fixtures')
|
24
|
+
|
25
|
+
I18n.config.enforce_available_locales = true
|
26
|
+
|
27
|
+
class ActiveSupport::TestCase
|
28
|
+
include ActiveRecord::TestFixtures
|
29
|
+
|
30
|
+
self.fixture_path = File.dirname(__FILE__) + '/fixtures/'
|
31
|
+
self.use_instantiated_fixtures = false
|
32
|
+
self.use_transactional_tests = true
|
33
|
+
self.test_order = :random
|
34
|
+
|
35
|
+
def assert_date_from_db(expected, actual, message = nil)
|
36
|
+
# SQL Server doesn't have a separate column type just for dates,
|
37
|
+
# so the time is in the string and incorrectly formatted
|
38
|
+
if current_adapter?(:SQLServerAdapter)
|
39
|
+
assert_equal expected.strftime('%Y/%m/%d 00:00:00'), actual.strftime('%Y/%m/%d 00:00:00')
|
40
|
+
elsif current_adapter?(:SybaseAdapter)
|
41
|
+
assert_equal expected.to_s, actual.to_date.to_s, message
|
42
|
+
else
|
43
|
+
assert_equal expected.to_s, actual.to_s, message
|
44
|
+
end
|
45
|
+
end
|
46
|
+
|
47
|
+
def assert_queries(num = 1)
|
48
|
+
ActiveRecord::Base.connection.class.class_eval do
|
49
|
+
self.query_count = 0
|
50
|
+
alias_method :execute, :execute_with_query_counting
|
51
|
+
end
|
52
|
+
yield
|
53
|
+
ensure
|
54
|
+
ActiveRecord::Base.connection.class.class_eval do
|
55
|
+
alias_method :execute, :execute_without_query_counting
|
56
|
+
end
|
57
|
+
assert_equal num, ActiveRecord::Base.connection.query_count, '#{ActiveRecord::Base.connection.query_count} instead of #{num} queries were executed.'
|
58
|
+
end
|
59
|
+
|
60
|
+
def assert_no_queries(&block)
|
61
|
+
assert_queries(0, &block)
|
62
|
+
end
|
63
|
+
|
64
|
+
cattr_accessor :classes
|
65
|
+
|
66
|
+
protected
|
67
|
+
|
68
|
+
def testing_with(&block)
|
69
|
+
classes.keys.each do |key_test|
|
70
|
+
@key_test = key_test
|
71
|
+
@klass_info = classes[@key_test]
|
72
|
+
@klass, @primary_keys = @klass_info[:class], @klass_info[:primary_keys]
|
73
|
+
order = @klass.primary_key.is_a?(String) ? @klass.primary_key : @klass.primary_key.join(',')
|
74
|
+
@first = @klass.order(order).first
|
75
|
+
yield
|
76
|
+
end
|
77
|
+
end
|
78
|
+
|
79
|
+
def first_id
|
80
|
+
ids = (1..@primary_keys.length).map {|num| 1}
|
81
|
+
composite? ? ids.to_composite_ids : ids.first
|
82
|
+
end
|
83
|
+
|
84
|
+
def composite?
|
85
|
+
@key_test != :single
|
86
|
+
end
|
87
|
+
|
88
|
+
# Oracle metadata is in all caps.
|
89
|
+
def with_quoted_identifiers(s)
|
90
|
+
s.gsub(/'(\w+)'/) { |m|
|
91
|
+
if ActiveRecord::Base.configurations[:test]['adapter'] =~ /oracle/i
|
92
|
+
m.upcase
|
93
|
+
else
|
94
|
+
m
|
95
|
+
end
|
96
|
+
}
|
97
|
+
end
|
98
|
+
end
|
99
|
+
|
100
|
+
def current_adapter?(type)
|
101
|
+
ActiveRecord::ConnectionAdapters.const_defined?(type) &&
|
102
|
+
ActiveRecord::Base.connection.instance_of?(ActiveRecord::ConnectionAdapters.const_get(type))
|
103
|
+
end
|
104
|
+
|
105
|
+
ActiveRecord::Base.connection.class.class_eval do
|
106
|
+
cattr_accessor :query_count
|
107
|
+
alias_method :execute_without_query_counting, :execute
|
108
|
+
def execute_with_query_counting(sql, name = nil)
|
109
|
+
self.query_count += 1
|
110
|
+
execute_without_query_counting(sql, name)
|
111
|
+
end
|
112
|
+
end
|
113
|
+
|
114
|
+
ActiveRecord::Base.logger = Logger.new(ENV['CPK_LOGFILE'] || STDOUT)
|
@@ -1,19 +1,22 @@
|
|
1
|
-
mysql:
|
2
|
-
adapter: mysql2
|
3
|
-
username:
|
4
|
-
password:
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
1
|
+
mysql:
|
2
|
+
adapter: mysql2
|
3
|
+
username: github
|
4
|
+
password: github
|
5
|
+
host: 127.0.0.1
|
6
|
+
port: 3306
|
7
|
+
encoding: utf8mb4
|
8
|
+
charset: utf8mb4
|
9
|
+
collation: utf8mb4_bin
|
10
|
+
database: composite_primary_keys_unittest
|
11
|
+
|
12
|
+
postgresql:
|
13
|
+
adapter: postgresql
|
14
|
+
database: composite_primary_keys_unittest
|
15
|
+
username: postgres
|
16
|
+
password: postgres
|
17
|
+
host: localhost
|
18
|
+
|
19
|
+
sqlite:
|
20
|
+
adapter: sqlite3
|
21
|
+
database: <%= File.join(project_root, 'db', 'composite_primary_keys_unittest.sqlite') %>
|
22
|
+
|
data/test/fixtures/article.rb
CHANGED
@@ -2,5 +2,9 @@ class Article < ActiveRecord::Base
|
|
2
2
|
validates :id, uniqueness: true, numericality: true, allow_nil: true, allow_blank: true, on: :create
|
3
3
|
has_many :readings, :dependent => :delete_all
|
4
4
|
has_many :users, :through => :readings
|
5
|
+
|
6
|
+
has_many :comments, :dependent => :delete_all
|
7
|
+
has_many :employee_commentators, :through => :comments, :source => :person, :source_type => :employee
|
8
|
+
has_many :user_commentators, :through => :comments, :source => :person, :source_type => "User"
|
5
9
|
end
|
6
10
|
|
data/test/fixtures/articles.yml
CHANGED
data/test/fixtures/comment.rb
CHANGED
data/test/fixtures/comments.yml
CHANGED
@@ -1,16 +1,17 @@
|
|
1
|
-
|
1
|
+
employee_comment:
|
2
2
|
id: 1
|
3
|
+
article: first
|
3
4
|
person_id: 1
|
4
5
|
person_type: Employee
|
5
|
-
|
6
|
-
|
6
|
+
|
7
|
+
user_comment_1:
|
7
8
|
id: 2
|
9
|
+
article: second
|
8
10
|
person_id: 1
|
9
11
|
person_type: User
|
10
|
-
|
11
|
-
|
12
|
-
comment3:
|
12
|
+
|
13
|
+
user_comment_2:
|
13
14
|
id: 3
|
14
|
-
|
15
|
-
|
16
|
-
|
15
|
+
article: second
|
16
|
+
person_id: 2
|
17
|
+
person_type: User
|
@@ -1,126 +1,112 @@
|
|
1
|
-
CREATE TABLE
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
)
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
)
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
)
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
PRIMARY KEY (
|
36
|
-
);
|
37
|
-
|
38
|
-
CREATE TABLE
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
PRIMARY KEY (
|
43
|
-
);
|
44
|
-
|
45
|
-
CREATE TABLE
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
)
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
name varchar(50) NOT NULL,
|
56
|
-
PRIMARY KEY (
|
57
|
-
);
|
58
|
-
|
59
|
-
CREATE TABLE
|
60
|
-
id integer NOT NULL ,
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
PRIMARY KEY (id)
|
71
|
-
);
|
72
|
-
|
73
|
-
CREATE TABLE
|
74
|
-
id integer NOT NULL ,
|
75
|
-
name varchar(50) NOT NULL,
|
76
|
-
PRIMARY KEY (id)
|
77
|
-
);
|
78
|
-
|
79
|
-
CREATE TABLE
|
80
|
-
|
81
|
-
|
82
|
-
|
83
|
-
|
84
|
-
|
85
|
-
|
86
|
-
|
87
|
-
|
88
|
-
|
89
|
-
|
90
|
-
PRIMARY KEY
|
91
|
-
);
|
92
|
-
|
93
|
-
|
94
|
-
|
95
|
-
|
96
|
-
|
97
|
-
|
98
|
-
|
99
|
-
|
100
|
-
|
101
|
-
|
102
|
-
|
103
|
-
|
104
|
-
|
105
|
-
|
106
|
-
|
107
|
-
|
108
|
-
|
109
|
-
|
110
|
-
|
111
|
-
|
112
|
-
|
113
|
-
);
|
114
|
-
|
115
|
-
create table restaurants_suburbs (
|
116
|
-
franchise_id integer not null,
|
117
|
-
store_id integer not null,
|
118
|
-
city_id integer not null,
|
119
|
-
suburb_id integer not null
|
120
|
-
);
|
121
|
-
|
122
|
-
create table products_restaurants (
|
123
|
-
product_id integer not null,
|
124
|
-
franchise_id integer not null,
|
125
|
-
store_id integer not null
|
126
|
-
);
|
1
|
+
CREATE TABLE reference_types (
|
2
|
+
reference_type_id integer NOT NULL generated by default as identity (start with 100, increment by 1, no cache),
|
3
|
+
type_label varchar(50) default NULL,
|
4
|
+
abbreviation varchar(50) default NULL,
|
5
|
+
description varchar(50) default NULL,
|
6
|
+
PRIMARY KEY (reference_type_id)
|
7
|
+
);
|
8
|
+
|
9
|
+
CREATE TABLE reference_codes (
|
10
|
+
reference_type_id integer,
|
11
|
+
reference_code integer NOT NULL,
|
12
|
+
code_label varchar(50) default NULL,
|
13
|
+
abbreviation varchar(50) default NULL,
|
14
|
+
description varchar(50) default NULL,
|
15
|
+
PRIMARY KEY (reference_type_id,reference_code)
|
16
|
+
);
|
17
|
+
|
18
|
+
CREATE TABLE products (
|
19
|
+
id integer NOT NULL,
|
20
|
+
name varchar(50) default NULL,
|
21
|
+
PRIMARY KEY (id)
|
22
|
+
);
|
23
|
+
|
24
|
+
CREATE TABLE tariffs (
|
25
|
+
tariff_id integer NOT NULL,
|
26
|
+
start_date date NOT NULL,
|
27
|
+
amount integer default NULL,
|
28
|
+
PRIMARY KEY (tariff_id,start_date)
|
29
|
+
);
|
30
|
+
|
31
|
+
CREATE TABLE product_tariffs (
|
32
|
+
product_id integer NOT NULL,
|
33
|
+
tariff_id integer NOT NULL,
|
34
|
+
tariff_start_date date NOT NULL,
|
35
|
+
PRIMARY KEY (product_id,tariff_id,tariff_start_date)
|
36
|
+
);
|
37
|
+
|
38
|
+
CREATE TABLE suburbs (
|
39
|
+
city_id integer NOT NULL,
|
40
|
+
suburb_id integer NOT NULL,
|
41
|
+
name varchar(50) NOT NULL,
|
42
|
+
PRIMARY KEY (city_id,suburb_id)
|
43
|
+
);
|
44
|
+
|
45
|
+
CREATE TABLE streets (
|
46
|
+
id integer NOT NULL ,
|
47
|
+
city_id integer NOT NULL,
|
48
|
+
suburb_id integer NOT NULL,
|
49
|
+
name varchar(50) NOT NULL,
|
50
|
+
PRIMARY KEY (id)
|
51
|
+
);
|
52
|
+
|
53
|
+
CREATE TABLE users (
|
54
|
+
id integer NOT NULL ,
|
55
|
+
name varchar(50) NOT NULL,
|
56
|
+
PRIMARY KEY (id)
|
57
|
+
);
|
58
|
+
|
59
|
+
CREATE TABLE articles (
|
60
|
+
id integer NOT NULL ,
|
61
|
+
name varchar(50) NOT NULL,
|
62
|
+
PRIMARY KEY (id)
|
63
|
+
);
|
64
|
+
|
65
|
+
CREATE TABLE readings (
|
66
|
+
id integer NOT NULL ,
|
67
|
+
user_id integer NOT NULL,
|
68
|
+
article_id integer NOT NULL,
|
69
|
+
rating integer NOT NULL,
|
70
|
+
PRIMARY KEY (id)
|
71
|
+
);
|
72
|
+
|
73
|
+
CREATE TABLE groups (
|
74
|
+
id integer NOT NULL ,
|
75
|
+
name varchar(50) NOT NULL,
|
76
|
+
PRIMARY KEY (id)
|
77
|
+
);
|
78
|
+
|
79
|
+
CREATE TABLE memberships (
|
80
|
+
user_id integer NOT NULL,
|
81
|
+
group_id integer NOT NULL,
|
82
|
+
PRIMARY KEY (user_id,group_id)
|
83
|
+
);
|
84
|
+
|
85
|
+
CREATE TABLE membership_statuses (
|
86
|
+
id integer NOT NULL ,
|
87
|
+
user_id integer NOT NULL,
|
88
|
+
group_id integer NOT NULL,
|
89
|
+
status varchar(50) NOT NULL,
|
90
|
+
PRIMARY KEY (id)
|
91
|
+
);
|
92
|
+
|
93
|
+
create table restaurants (
|
94
|
+
franchise_id integer not null,
|
95
|
+
store_id integer not null,
|
96
|
+
name varchar(100),
|
97
|
+
lock_version integer default 0,
|
98
|
+
primary key (franchise_id, store_id)
|
99
|
+
);
|
100
|
+
|
101
|
+
create table restaurants_suburbs (
|
102
|
+
franchise_id integer not null,
|
103
|
+
store_id integer not null,
|
104
|
+
city_id integer not null,
|
105
|
+
suburb_id integer not null
|
106
|
+
);
|
107
|
+
|
108
|
+
create table products_restaurants (
|
109
|
+
product_id integer not null,
|
110
|
+
franchise_id integer not null,
|
111
|
+
store_id integer not null
|
112
|
+
);
|
@@ -1,19 +1,17 @@
|
|
1
|
-
drop table MEMBERSHIPS;
|
2
|
-
drop table REFERENCE_CODES;
|
3
|
-
drop table TARIFFS;
|
4
|
-
drop table ARTICLES;
|
5
|
-
drop table GROUPS;
|
6
|
-
drop table MEMBERSHIP_STATUSES;
|
7
|
-
drop table READINGS;
|
8
|
-
drop table REFERENCE_TYPES;
|
9
|
-
drop table STREETS;
|
10
|
-
drop table PRODUCTS;
|
11
|
-
drop table USERS;
|
12
|
-
drop table SUBURBS;
|
13
|
-
drop table PRODUCT_TARIFFS;
|
14
|
-
drop table KITCHEN_SINK;
|
15
|
-
drop table RESTAURANTS;
|
16
|
-
drop table RESTAURANTS_SUBURBS;
|
17
|
-
drop table PRODUCTS_RESTAURANTS;
|
18
|
-
drop table TOPICS;
|
19
|
-
drop table TOPIC_SOURCES;
|
1
|
+
drop table MEMBERSHIPS;
|
2
|
+
drop table REFERENCE_CODES;
|
3
|
+
drop table TARIFFS;
|
4
|
+
drop table ARTICLES;
|
5
|
+
drop table GROUPS;
|
6
|
+
drop table MEMBERSHIP_STATUSES;
|
7
|
+
drop table READINGS;
|
8
|
+
drop table REFERENCE_TYPES;
|
9
|
+
drop table STREETS;
|
10
|
+
drop table PRODUCTS;
|
11
|
+
drop table USERS;
|
12
|
+
drop table SUBURBS;
|
13
|
+
drop table PRODUCT_TARIFFS;
|
14
|
+
drop table KITCHEN_SINK;
|
15
|
+
drop table RESTAURANTS;
|
16
|
+
drop table RESTAURANTS_SUBURBS;
|
17
|
+
drop table PRODUCTS_RESTAURANTS;
|