-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathpostgres-ddl.sql
More file actions
281 lines (227 loc) · 6.49 KB
/
Copy pathpostgres-ddl.sql
File metadata and controls
281 lines (227 loc) · 6.49 KB
1
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
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
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
--
-- PostgreSQL database dump
--
SET statement_timeout = 0;
SET lock_timeout = 0;
SET client_encoding = 'UTF8';
SET standard_conforming_strings = on;
SET check_function_bodies = false;
SET client_min_messages = warning;
SET search_path = public, pg_catalog;
SET default_tablespace = '';
SET default_with_oids = false;
--
-- Name: candidate_committee_linkage; Type: TABLE; Schema: public; Owner: postgres; Tablespace:
--
CREATE TABLE candidate_committee_linkage (
candidate_identification text,
candidate_election_year bigint,
fec_election_year bigint,
committee_identification text,
committee_type text,
committee_designation text,
linkage_id bigint
);
ALTER TABLE public.candidate_committee_linkage OWNER TO postgres;
--
-- Name: candidate_master; Type: TABLE; Schema: public; Owner: postgres; Tablespace:
--
CREATE TABLE candidate_master (
candidate_identification text,
candidate_name text,
party_affiliation text,
year_of_election bigint,
candidate_state text,
candidate_office text,
candidate_district text,
incumbent_challenger_status text,
candidate_status text,
principal_campaign_committee text,
mailing_address_street text,
mailing_address_street2 text,
mailing_address_city text,
mailing_address_state text,
mailing_address_zip text
);
ALTER TABLE public.candidate_master OWNER TO postgres;
--
-- Name: committee_master; Type: TABLE; Schema: public; Owner: postgres; Tablespace:
--
CREATE TABLE committee_master (
committee_identification text,
committee_name text,
treasurers_name text,
street_one text,
street_two text,
city_or_town text,
state text,
zip text,
committee_designation text,
committee_type text,
committee_party text,
filing_frequency text,
interest_group_category text,
connected_organizations_name text,
candidate_identification text
);
ALTER TABLE public.committee_master OWNER TO postgres;
--
-- Name: committee_to_candidate; Type: TABLE; Schema: public; Owner: postgres; Tablespace:
--
CREATE TABLE committee_to_candidate (
filer_identification_number text,
amendment_indicator text,
report_type text,
primary_general_indicator text,
image_number text,
transaction_type text,
entity_type text,
recipient_or_payee text,
city_or_town text,
state text,
zip_code text,
employer text,
occupation text,
transaction_date text,
transaction_amount double precision,
other_identification_number text,
candidate_identification_number text,
transaction_id text,
file_number_or_report_id text,
memo_code text,
memo_text text,
fec_record_number bigint
);
ALTER TABLE public.committee_to_candidate OWNER TO postgres;
--
-- Name: committee_type; Type: TABLE; Schema: public; Owner: postgres; Tablespace:
--
CREATE TABLE committee_type (
committee_type_code text,
committee_type text,
explanation text
);
ALTER TABLE public.committee_type OWNER TO postgres;
--
-- Name: disbursment_type; Type: TABLE; Schema: public; Owner: postgres; Tablespace:
--
CREATE TABLE disbursment_type (
disbursment_category_code bigint,
disbursment_category_code_description text
);
ALTER TABLE public.disbursment_type OWNER TO postgres;
--
-- Name: individual_contributions; Type: TABLE; Schema: public; Owner: postgres; Tablespace:
--
CREATE TABLE individual_contributions (
filer_identification_number text,
amendment_indicator text,
report_type text,
primary_general_indicator text,
image_number text,
transaction_type text,
entity_type text,
contributor_or_lender_or_transfer_name text,
city_or_town text,
state text,
zip_code text,
employer text,
occupation text,
transaction_date text,
transaction_amount double precision,
other_identification_number text,
transaction_id text,
file_number_or_report_id text,
memo_code text,
memo_text text,
fec_record_number text
);
ALTER TABLE public.individual_contributions OWNER TO postgres;
--
-- Name: inter_committee_transactions; Type: TABLE; Schema: public; Owner: postgres; Tablespace:
--
CREATE TABLE inter_committee_transactions (
filer_identification_number text,
amendment_indicator text,
report_type text,
primary_general_indicator text,
image_number text,
transaction_type text,
entity_type text,
contributor_or_lender_or_transfer_name text,
city_or_town text,
state text,
zip_code text,
employer text,
occupation text,
transaction_date text,
transaction_amount double precision,
other_identification_number text,
transaction_id text,
file_number_or_report_id text,
memo_code text,
memo_text text,
fec_record_number bigint
);
ALTER TABLE public.inter_committee_transactions OWNER TO postgres;
--
-- Name: operating_expenditures; Type: TABLE; Schema: public; Owner: postgres; Tablespace:
--
CREATE TABLE operating_expenditures (
filer_identification_number text,
amendment_indicator text,
report_year bigint,
report_type text,
image_number text,
line_number text,
form_type text,
schedule_type text,
contributor_or_lender_or_transfer_name text,
city_or_town text,
state text,
zip_code text,
transaction_date timestamp without time zone,
transaction_amount double precision,
primary_general_indicator text,
purpose text,
disbursement_category_code text,
disbursement_category_code_description text,
memo_code text,
memo_text text,
entity_type text,
fec_record_number text,
file_number_or_report_id text,
transaction_id text,
back_reference_transaction_id text,
null_column text
);
ALTER TABLE public.operating_expenditures OWNER TO postgres;
--
-- Name: party_codes; Type: TABLE; Schema: public; Owner: postgres; Tablespace:
--
CREATE TABLE party_codes (
party_code text,
party_code_description text,
notes text
);
ALTER TABLE public.party_codes OWNER TO postgres;
--
-- Name: report_type; Type: TABLE; Schema: public; Owner: postgres; Tablespace:
--
CREATE TABLE report_type (
report_type_code text,
report_type text,
explanation text
);
ALTER TABLE public.report_type OWNER TO postgres;
--
-- Name: transaction_type; Type: TABLE; Schema: public; Owner: postgres; Tablespace:
--
CREATE TABLE transaction_type (
transaction_type text,
transaction_type_description text
);
ALTER TABLE public.transaction_type OWNER TO postgres;
--
-- PostgreSQL database dump complete
--