FazBrowse GitHub Viewer
|
Trending
|
URL:
|
Home
Tools:
[Download Repo ZIP]
[View Raw Code]
[Original HTTPS Page]
documentcloud/db/structure.sql at master · documentcloud/documentcloud · GitHub
Uh oh!
There was an error while loading.
Please reload this page
.
This repository was archived by the owner on Mar 11, 2021. It is now read-only.
documentcloud
/
documentcloud
Public archive
Notifications
You must be signed in to change notification settings
Fork
157
Star
425
Code
Issues
194
Pull requests
16
Actions
Projects
Wiki
Security and quality
0
Insights
Additional navigation options
Code
Issues
Pull requests
Actions
Projects
Wiki
Security and quality
Insights
Expand file tree
Breadcrumbs
documentcloud
/
db
/
structure.sql
Copy path
More file actions
More file actions
Latest commit
History
History
History
1820 lines (1250 loc) · 41 KB
Breadcrumbs
documentcloud
/
db
/
structure.sql
Copy path
File metadata and controls
1820 lines (1250 loc) · 41 KB
Raw
Copy raw file
Download raw file
Open symbols panel
Edit and raw actions
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
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
--
--
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;
--
--
Name: plpgsql; Type: EXTENSION; Schema: -; Owner: -
--
CREATE EXTENSION IF NOT EXISTS plpgsql WITH SCHEMA pg_catalog;
--
--
Name: EXTENSION plpgsql; Type: COMMENT; Schema: -; Owner: -
--
COMMENT
ON
EXTENSION plpgsql IS
'
PL/pgSQL procedural language
'
;
--
--
Name: dblink; Type: EXTENSION; Schema: -; Owner: -
--
CREATE EXTENSION IF NOT EXISTS dblink WITH SCHEMA public;
--
--
Name: EXTENSION dblink; Type: COMMENT; Schema: -; Owner: -
--
COMMENT
ON
EXTENSION dblink IS
'
connect to other PostgreSQL databases from within a database
'
;
SET
search_path
=
public, pg_catalog;
--
--
Name: ghstore; Type: SHELL TYPE; Schema: public; Owner: -
--
CREATE
TYPE
ghstore
;
--
--
Name: ghstore_in(cstring); Type: FUNCTION; Schema: public; Owner: -
--
CREATE
FUNCTION
ghstore_in
(cstring) RETURNS ghstore
LANGUAGE c STRICT
AS
'
$libdir/hstore
'
,
'
ghstore_in
'
;
--
--
Name: ghstore_out(ghstore); Type: FUNCTION; Schema: public; Owner: -
--
CREATE
FUNCTION
ghstore_out
(ghstore) RETURNS cstring
LANGUAGE c STRICT
AS
'
$libdir/hstore
'
,
'
ghstore_out
'
;
--
--
Name: ghstore; Type: TYPE; Schema: public; Owner: -
--
CREATE
TYPE
ghstore
(
INTERNALLENGTH
=
variable,
INPUT
=
ghstore_in,
OUTPUT
=
ghstore_out,
ALIGNMENT
=
int4,
STORAGE
=
plain
);
--
--
Name: hstore; Type: SHELL TYPE; Schema: public; Owner: -
--
CREATE
TYPE
hstore
;
--
--
Name: hstore_in(cstring); Type: FUNCTION; Schema: public; Owner: -
--
CREATE
FUNCTION
hstore_in
(cstring) RETURNS hstore
LANGUAGE c STRICT
AS
'
$libdir/hstore
'
,
'
hstore_in
'
;
--
--
Name: hstore_out(hstore); Type: FUNCTION; Schema: public; Owner: -
--
CREATE
FUNCTION
hstore_out
(hstore) RETURNS cstring
LANGUAGE c STRICT
AS
'
$libdir/hstore
'
,
'
hstore_out
'
;
--
--
Name: hstore; Type: TYPE; Schema: public; Owner: -
--
CREATE
TYPE
hstore
(
INTERNALLENGTH
=
variable,
INPUT
=
hstore_in,
OUTPUT
=
hstore_out,
ALIGNMENT
=
int4,
STORAGE
=
extended
);
--
--
Name: akeys(hstore); Type: FUNCTION; Schema: public; Owner: -
--
CREATE
FUNCTION
akeys
(hstore) RETURNS
text
[]
LANGUAGE c IMMUTABLE STRICT
AS
'
$libdir/hstore
'
,
'
akeys
'
;
--
--
Name: avals(hstore); Type: FUNCTION; Schema: public; Owner: -
--
CREATE
FUNCTION
avals
(hstore) RETURNS
text
[]
LANGUAGE c IMMUTABLE STRICT
AS
'
$libdir/hstore
'
,
'
avals
'
;
--
--
Name: defined(hstore, text); Type: FUNCTION; Schema: public; Owner: -
--
CREATE
FUNCTION
defined
(hstore,
text
) RETURNS
boolean
LANGUAGE c IMMUTABLE STRICT
AS
'
$libdir/hstore
'
,
'
defined
'
;
--
--
Name: delete(hstore, text); Type: FUNCTION; Schema: public; Owner: -
--
CREATE
FUNCTION
delete
(hstore,
text
) RETURNS hstore
LANGUAGE c IMMUTABLE STRICT
AS
'
$libdir/hstore
'
,
'
delete
'
;
--
--
Name: each(hstore); Type: FUNCTION; Schema: public; Owner: -
--
CREATE
FUNCTION
each
(hs hstore, OUT key
text
, OUT value
text
) RETURNS SETOF record
LANGUAGE c IMMUTABLE STRICT
AS
'
$libdir/hstore
'
,
'
each
'
;
--
--
Name: exist(hstore, text); Type: FUNCTION; Schema: public; Owner: -
--
CREATE
FUNCTION
exist
(hstore,
text
) RETURNS
boolean
LANGUAGE c IMMUTABLE STRICT
AS
'
$libdir/hstore
'
,
'
exists
'
;
--
--
Name: fetchval(hstore, text); Type: FUNCTION; Schema: public; Owner: -
--
CREATE
FUNCTION
fetchval
(hstore,
text
) RETURNS
text
LANGUAGE c IMMUTABLE STRICT
AS
'
$libdir/hstore
'
,
'
fetchval
'
;
--
--
Name: ghstore_compress(internal); Type: FUNCTION; Schema: public; Owner: -
--
CREATE
FUNCTION
ghstore_compress
(internal) RETURNS internal
LANGUAGE c IMMUTABLE STRICT
AS
'
$libdir/hstore
'
,
'
ghstore_compress
'
;
--
--
Name: ghstore_consistent(internal, internal, integer, oid, internal); Type: FUNCTION; Schema: public; Owner: -
--
CREATE
FUNCTION
ghstore_consistent
(internal, internal,
integer
,
oid
, internal) RETURNS
boolean
LANGUAGE c IMMUTABLE STRICT
AS
'
$libdir/hstore
'
,
'
ghstore_consistent
'
;
--
--
Name: ghstore_decompress(internal); Type: FUNCTION; Schema: public; Owner: -
--
CREATE
FUNCTION
ghstore_decompress
(internal) RETURNS internal
LANGUAGE c IMMUTABLE STRICT
AS
'
$libdir/hstore
'
,
'
ghstore_decompress
'
;
--
--
Name: ghstore_penalty(internal, internal, internal); Type: FUNCTION; Schema: public; Owner: -
--
CREATE
FUNCTION
ghstore_penalty
(internal, internal, internal) RETURNS internal
LANGUAGE c IMMUTABLE STRICT
AS
'
$libdir/hstore
'
,
'
ghstore_penalty
'
;
--
--
Name: ghstore_picksplit(internal, internal); Type: FUNCTION; Schema: public; Owner: -
--
CREATE
FUNCTION
ghstore_picksplit
(internal, internal) RETURNS internal
LANGUAGE c IMMUTABLE STRICT
AS
'
$libdir/hstore
'
,
'
ghstore_picksplit
'
;
--
--
Name: ghstore_same(internal, internal, internal); Type: FUNCTION; Schema: public; Owner: -
--
CREATE
FUNCTION
ghstore_same
(internal, internal, internal) RETURNS internal
LANGUAGE c IMMUTABLE STRICT
AS
'
$libdir/hstore
'
,
'
ghstore_same
'
;
--
--
Name: ghstore_union(internal, internal); Type: FUNCTION; Schema: public; Owner: -
--
CREATE
FUNCTION
ghstore_union
(internal, internal) RETURNS internal
LANGUAGE c IMMUTABLE STRICT
AS
'
$libdir/hstore
'
,
'
ghstore_union
'
;
--
--
Name: gin_consistent_hstore(internal, smallint, internal, integer, internal, internal); Type: FUNCTION; Schema: public; Owner: -
--
CREATE
FUNCTION
gin_consistent_hstore
(internal,
smallint
, internal,
integer
, internal, internal) RETURNS
boolean
LANGUAGE c IMMUTABLE STRICT
AS
'
$libdir/hstore
'
,
'
gin_consistent_hstore
'
;
--
--
Name: gin_extract_hstore(internal, internal); Type: FUNCTION; Schema: public; Owner: -
--
CREATE
FUNCTION
gin_extract_hstore
(internal, internal) RETURNS internal
LANGUAGE c IMMUTABLE STRICT
AS
'
$libdir/hstore
'
,
'
gin_extract_hstore
'
;
--
--
Name: gin_extract_hstore_query(internal, internal, smallint, internal, internal); Type: FUNCTION; Schema: public; Owner: -
--
CREATE
FUNCTION
gin_extract_hstore_query
(internal, internal,
smallint
, internal, internal) RETURNS internal
LANGUAGE c IMMUTABLE STRICT
AS
'
$libdir/hstore
'
,
'
gin_extract_hstore_query
'
;
--
--
Name: hs_concat(hstore, hstore); Type: FUNCTION; Schema: public; Owner: -
--
CREATE
FUNCTION
hs_concat
(hstore, hstore) RETURNS hstore
LANGUAGE c IMMUTABLE STRICT
AS
'
$libdir/hstore
'
,
'
hs_concat
'
;
--
--
Name: hs_contained(hstore, hstore); Type: FUNCTION; Schema: public; Owner: -
--
CREATE
FUNCTION
hs_contained
(hstore, hstore) RETURNS
boolean
LANGUAGE c IMMUTABLE STRICT
AS
'
$libdir/hstore
'
,
'
hs_contained
'
;
--
--
Name: hs_contains(hstore, hstore); Type: FUNCTION; Schema: public; Owner: -
--
CREATE
FUNCTION
hs_contains
(hstore, hstore) RETURNS
boolean
LANGUAGE c IMMUTABLE STRICT
AS
'
$libdir/hstore
'
,
'
hs_contains
'
;
--
--
Name: hstore(text, text); Type: FUNCTION; Schema: public; Owner: -
--
CREATE
FUNCTION
hstore
(
text
,
text
) RETURNS hstore
LANGUAGE c IMMUTABLE
AS
'
$libdir/hstore
'
,
'
tconvert
'
;
--
--
Name: isdefined(hstore, text); Type: FUNCTION; Schema: public; Owner: -
--
CREATE
FUNCTION
isdefined
(hstore,
text
) RETURNS
boolean
LANGUAGE c IMMUTABLE STRICT
AS
'
$libdir/hstore
'
,
'
defined
'
;
--
--
Name: isexists(hstore, text); Type: FUNCTION; Schema: public; Owner: -
--
CREATE
FUNCTION
isexists
(hstore,
text
) RETURNS
boolean
LANGUAGE c IMMUTABLE STRICT
AS
'
$libdir/hstore
'
,
'
exists
'
;
--
--
Name: skeys(hstore); Type: FUNCTION; Schema: public; Owner: -
--
CREATE
FUNCTION
skeys
(hstore) RETURNS SETOF
text
LANGUAGE c IMMUTABLE STRICT
AS
'
$libdir/hstore
'
,
'
skeys
'
;
--
--
Name: svals(hstore); Type: FUNCTION; Schema: public; Owner: -
--
CREATE
FUNCTION
svals
(hstore) RETURNS SETOF
text
LANGUAGE c IMMUTABLE STRICT
AS
'
$libdir/hstore
'
,
'
svals
'
;
--
--
Name: tconvert(text, text); Type: FUNCTION; Schema: public; Owner: -
--
CREATE
FUNCTION
tconvert
(
text
,
text
) RETURNS hstore
LANGUAGE c IMMUTABLE
AS
'
$libdir/hstore
'
,
'
tconvert
'
;
--
--
Name: ->; Type: OPERATOR; Schema: public; Owner: -
--
CREATE OPERATOR
-
>
(
PROCEDURE
=
fetchval,
LEFTARG
=
hstore,
RIGHTARG
=
text
);
--
--
Name: <@; Type: OPERATOR; Schema: public; Owner: -
--
CREATE OPERATOR
<
@ (
PROCEDURE
=
hs_contained,
LEFTARG
=
hstore,
RIGHTARG
=
hstore,
COMMUTATOR
=
@
>
,
RESTRICT
=
contsel,
JOIN
=
contjoinsel
);
--
--
Name: =>; Type: OPERATOR; Schema: public; Owner: -
--
CREATE OPERATOR
=>
(
PROCEDURE
=
tconvert,
LEFTARG
=
text
,
RIGHTARG
=
text
);
--
--
Name: ?; Type: OPERATOR; Schema: public; Owner: -
--
CREATE OPERATOR ? (
PROCEDURE
=
exist,
LEFTARG
=
hstore,
RIGHTARG
=
text
,
RESTRICT
=
contsel,
JOIN
=
contjoinsel
);
--
--
Name: @; Type: OPERATOR; Schema: public; Owner: -
--
CREATE OPERATOR @ (
PROCEDURE
=
hs_contains,
LEFTARG
=
hstore,
RIGHTARG
=
hstore,
COMMUTATOR
=
~,
RESTRICT
=
contsel,
JOIN
=
contjoinsel
);
--
--
Name: @>; Type: OPERATOR; Schema: public; Owner: -
--
CREATE OPERATOR @
>
(
PROCEDURE
=
hs_contains,
LEFTARG
=
hstore,
RIGHTARG
=
hstore,
COMMUTATOR
=
<
@,
RESTRICT
=
contsel,
JOIN
=
contjoinsel
);
--
--
Name: ||; Type: OPERATOR; Schema: public; Owner: -
--
CREATE OPERATOR
||
(
PROCEDURE
=
hs_concat,
LEFTARG
=
hstore,
RIGHTARG
=
hstore
);
--
--
Name: ~; Type: OPERATOR; Schema: public; Owner: -
--
CREATE OPERATOR ~ (
PROCEDURE
=
hs_contained,
LEFTARG
=
hstore,
RIGHTARG
=
hstore,
COMMUTATOR
=
@,
RESTRICT
=
contsel,
JOIN
=
contjoinsel
);
--
--
Name: gin_hstore_ops; Type: OPERATOR CLASS; Schema: public; Owner: -
--
CREATE
OPERATOR CLASS
gin_hstore_ops
DEFAULT FOR TYPE hstore USING gin
AS
STORAGE
text
,
OPERATOR
7
@
>
(hstore,hstore) ,
OPERATOR
9
?(hstore,
text
) ,
FUNCTION
1
(hstore, hstore) bttextcmp(
text
,
text
) ,
FUNCTION
2
(hstore, hstore) gin_extract_hstore(internal,internal) ,
FUNCTION
3
(hstore, hstore) gin_extract_hstore_query(internal,internal,
smallint
,internal,internal) ,
FUNCTION
4
(hstore, hstore) gin_consistent_hstore(internal,
smallint
,internal,
integer
,internal,internal);
--
--
Name: gist_hstore_ops; Type: OPERATOR CLASS; Schema: public; Owner: -
--
CREATE
OPERATOR CLASS
gist_hstore_ops
DEFAULT FOR TYPE hstore USING gist
AS
STORAGE ghstore ,
OPERATOR
7
@
>
(hstore,hstore) ,
OPERATOR
9
?(hstore,
text
) ,
OPERATOR
13
@(hstore,hstore) ,
FUNCTION
1
(hstore, hstore) ghstore_consistent(internal,internal,
integer
,
oid
,internal) ,
FUNCTION
2
(hstore, hstore) ghstore_union(internal,internal) ,
FUNCTION
3
(hstore, hstore) ghstore_compress(internal) ,
FUNCTION
4
(hstore, hstore) ghstore_decompress(internal) ,
FUNCTION
5
(hstore, hstore) ghstore_penalty(internal,internal,internal) ,
FUNCTION
6
(hstore, hstore) ghstore_picksplit(internal,internal) ,
FUNCTION
7
(hstore, hstore) ghstore_same(internal,internal,internal);
SET
default_tablespace
=
'
'
;
SET
default_with_oids
=
false;
--
--
Name: accounts; Type: TABLE; Schema: public; Owner: -; Tablespace:
--
CREATE
TABLE
accounts
(
id
integer
NOT NULL
,
first_name
character varying
(
40
),
last_name
character varying
(
40
),
email
character varying
(
100
),
hashed_password
character varying
(
255
),
created_at
timestamp without time zone
,
updated_at
timestamp without time zone
,
identities hstore,
language
character varying
(
3
) DEFAULT
'
eng
'
::character varying,
document_language
character varying
(
3
) DEFAULT
'
eng
'
::character varying
);
--
--
Name: accounts_id_seq; Type: SEQUENCE; Schema: public; Owner: -
--
CREATE
SEQUENCE
accounts_id_seq
START WITH
1
INCREMENT BY
1
NO MINVALUE
NO MAXVALUE
CACHE
1
;
--
--
Name: accounts_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: -
--
ALTER
SEQUENCE
accounts_id_seq OWNED BY
accounts
.
id
;
--
--
Name: annotations; Type: TABLE; Schema: public; Owner: -; Tablespace:
--
CREATE
TABLE
annotations
(
id
integer
NOT NULL
,
organization_id
integer
NOT NULL
,
account_id
integer
NOT NULL
,
document_id
integer
NOT NULL
,
page_number
integer
NOT NULL
,
access
integer
NOT NULL
,
title
text
NOT NULL
,
content
text
,
location
character varying
(
40
),
created_at
timestamp without time zone
,
updated_at
timestamp without time zone
);
--
--
Name: annotations_id_seq; Type: SEQUENCE; Schema: public; Owner: -
--
CREATE
SEQUENCE
annotations_id_seq
START WITH
1
INCREMENT BY
1
NO MINVALUE
NO MAXVALUE
CACHE
1
;
--
--
Name: annotations_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: -
--
ALTER
SEQUENCE
annotations_id_seq OWNED BY
annotations
.
id
;
--
--
Name: app_constants; Type: TABLE; Schema: public; Owner: -; Tablespace:
--
CREATE
TABLE
app_constants
(
id
integer
NOT NULL
,
key
character varying
(
255
),
value
character varying
(
255
)
);
--
--
Name: app_constants_id_seq; Type: SEQUENCE; Schema: public; Owner: -
--
CREATE
SEQUENCE
app_constants_id_seq
START WITH
1
INCREMENT BY
1
NO MINVALUE
NO MAXVALUE
CACHE
1
;
--
--
Name: app_constants_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: -
--
ALTER
SEQUENCE
app_constants_id_seq OWNED BY
app_constants
.
id
;
--
--
Name: bull_proof_china_shop_account_requests; Type: TABLE; Schema: public; Owner: -; Tablespace:
--
CREATE
TABLE
bull_proof_china_shop_account_requests
(
id
integer
NOT NULL
,
created_at
timestamp without time zone
,
updated_at
timestamp without time zone
,
requester_email
character varying
(
255
),
requester_first_name
character varying
(
255
),
requester_last_name
character varying
(
255
),
requester_notes
text
,
organization_name
character varying
(
255
),
organization_url
character varying
(
255
),
approver_email
character varying
(
255
),
approver_first_name
character varying
(
255
),
approver_last_name
character varying
(
255
),
country
character varying
(
255
)
NOT NULL
,
verification_notes
text
,
status
integer
DEFAULT
1
,
agreed_to_terms
boolean
DEFAULT false,
authorized_posting
boolean
DEFAULT false,
token
character varying
(
255
),
industry
character varying
(
255
),
use_case
text
,
reference_links
text
,
marketing_optin
boolean
DEFAULT false,
in_market
boolean
DEFAULT false,
requester_position character varying
);
--
--
Name: bull_proof_china_shop_account_requests_id_seq; Type: SEQUENCE; Schema: public; Owner: -
--
CREATE
SEQUENCE
bull_proof_china_shop_account_requests_id_seq
START WITH
1
INCREMENT BY
1
NO MINVALUE
NO MAXVALUE
CACHE
1
;
--
--
Name: bull_proof_china_shop_account_requests_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: -
--
ALTER
SEQUENCE
bull_proof_china_shop_account_requests_id_seq OWNED BY
bull_proof_china_shop_account_requests
.
id
;
--
--
Name: bull_proof_china_shop_accounts; Type: TABLE; Schema: public; Owner: -; Tablespace:
--
CREATE
TABLE
bull_proof_china_shop_accounts
(
id
integer
NOT NULL
,
stripe_customer_id character varying,
billing_email
text
,
dc_membership_id
integer
,
dc_membership_role
integer
,
dc_organization_id
integer
,
dc_account_id
integer
,
created_at
timestamp without time zone
NOT NULL
,
updated_at
timestamp without time zone
NOT NULL
);
--
--
Name: bull_proof_china_shop_accounts_id_seq; Type: SEQUENCE; Schema: public; Owner: -
--
CREATE
SEQUENCE
bull_proof_china_shop_accounts_id_seq
START WITH
1
INCREMENT BY
1
NO MINVALUE
NO MAXVALUE
CACHE
1
;
--
--
Name: bull_proof_china_shop_accounts_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: -
--
ALTER
SEQUENCE
bull_proof_china_shop_accounts_id_seq OWNED BY
bull_proof_china_shop_accounts
.
id
;
--
--
Name: bull_proof_china_shop_permits; Type: TABLE; Schema: public; Owner: -; Tablespace:
--
CREATE
TABLE
bull_proof_china_shop_permits
(
id
integer
NOT NULL
,
stripe_plan_id character varying,
stripe_customer_id character varying,
stripe_card_id character varying,
dc_membership_id
integer
,
dc_account_id
integer
,
dc_organization_id
integer
,
dc_membership_role
integer
,
status
integer
DEFAULT
1
,
created_at
timestamp without time zone
NOT NULL
,
updated_at
timestamp without time zone
NOT NULL
,
stripe_subscription_id character varying,
stripe_customer_email character varying,
stripe_card_last4
integer
,
account_id
integer
,
start_date
timestamp without time zone
,
end_date_scheduled
timestamp without time zone
,
end_date_actual
timestamp without time zone
);
--
--
Name: bull_proof_china_shop_permits_id_seq; Type: SEQUENCE; Schema: public; Owner: -
--
CREATE
SEQUENCE
bull_proof_china_shop_permits_id_seq
START WITH
1
INCREMENT BY
1
NO MINVALUE
NO MAXVALUE
CACHE
1
;
--
--
Name: bull_proof_china_shop_permits_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: -
--
ALTER
SEQUENCE
bull_proof_china_shop_permits_id_seq OWNED BY
bull_proof_china_shop_permits
.
id
;
--
--
Name: collaborations; Type: TABLE; Schema: public; Owner: -; Tablespace:
--
CREATE
TABLE
collaborations
(
id
integer
NOT NULL
,
project_id
integer
NOT NULL
,
account_id
integer
NOT NULL
,
creator_id
integer
);
--
--
Name: collaborations_id_seq; Type: SEQUENCE; Schema: public; Owner: -
--
CREATE
SEQUENCE
collaborations_id_seq
START WITH
1
INCREMENT BY
1
NO MINVALUE
NO MAXVALUE
CACHE
1
;
--
--
Name: collaborations_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: -
--
ALTER
SEQUENCE
collaborations_id_seq OWNED BY
collaborations
.
id
;
--
--
Name: docdata; Type: TABLE; Schema: public; Owner: -; Tablespace:
--
CREATE
TABLE
docdata
(
id
integer
NOT NULL
,
document_id
integer
NOT NULL
,
data hstore
);
--
--
Name: docdata_id_seq; Type: SEQUENCE; Schema: public; Owner: -
--
CREATE
SEQUENCE
docdata_id_seq
START WITH
1
INCREMENT BY
1
NO MINVALUE
NO MAXVALUE
CACHE
1
;
--
--
Name: docdata_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: -
--
ALTER
SEQUENCE
docdata_id_seq OWNED BY
docdata
.
id
;
--
--
Name: document_reviewers; Type: TABLE; Schema: public; Owner: -; Tablespace:
--
CREATE
TABLE
document_reviewers
(
id
integer
NOT NULL
,
account_id
integer
NOT NULL
,
document_id
integer
NOT NULL
,
created_at
timestamp without time zone
,
updated_at
timestamp without time zone
);
--
--
Name: document_reviewers_id_seq; Type: SEQUENCE; Schema: public; Owner: -
--
CREATE
SEQUENCE
document_reviewers_id_seq
START WITH
1
INCREMENT BY
1
NO MINVALUE
NO MAXVALUE
CACHE
1
;
--
--
Name: document_reviewers_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: -
--
ALTER
SEQUENCE
document_reviewers_id_seq OWNED BY
document_reviewers
.
id
;
--
--
Name: documents; Type: TABLE; Schema: public; Owner: -; Tablespace:
--
CREATE
TABLE
documents
(
id
integer
NOT NULL
,
organization_id
integer
NOT NULL
,
account_id
integer
NOT NULL
,
access
integer
NOT NULL
,
page_count
integer
DEFAULT
0
NOT NULL
,
title
character varying
(
1000
)
NOT NULL
,
slug
character varying
(
255
)
NOT NULL
,
source
character varying
(
1000
),
language
character varying
(
3
),
description
text
,
calais_id
character varying
(
40
),
publication_date
date
,
created_at
timestamp without time zone
,
updated_at
timestamp without time zone
,
related_article
text
,
detected_remote_url
text
,
remote_url
text
,
publish_at
timestamp without time zone
,
text_changed
boolean
DEFAULT false
NOT NULL
,
hit_count
integer
DEFAULT
0
NOT NULL
,
public_note_count
integer
DEFAULT
0
NOT NULL
,
file_size
integer
DEFAULT
0
NOT NULL
,
reviewer_count
integer
DEFAULT
0
NOT NULL
,
char_count
integer
DEFAULT
0
NOT NULL
,
original_extension
character varying
(
255
),
file_hash
text
);
--
--
Name: documents_id_seq; Type: SEQUENCE; Schema: public; Owner: -
--
CREATE
SEQUENCE
documents_id_seq
START WITH
1
INCREMENT BY
1
NO MINVALUE
NO MAXVALUE
CACHE
1
;
--
--
Name: documents_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: -
--
ALTER
SEQUENCE
documents_id_seq OWNED BY
documents
.
id
;
--
--
Name: entities; Type: TABLE; Schema: public; Owner: -; Tablespace:
--
CREATE
TABLE
entities
(
id
integer
NOT NULL
,
organization_id
integer
NOT NULL
,
account_id
integer
NOT NULL
,
document_id
integer
NOT NULL
,
access
integer
NOT NULL
,
kind
character varying
(
40
)
NOT NULL
,
value
character varying
(
255
)
NOT NULL
,
relevance
double precision
DEFAULT
0
.
0
NOT NULL
,
calais_id
character varying
(
40
),
occurrences
text
);
--
--
Name: entity_dates; Type: TABLE; Schema: public; Owner: -; Tablespace:
--
CREATE
TABLE
entity_dates
(
id
integer
NOT NULL
,
organization_id
integer
NOT NULL
,
account_id
integer
NOT NULL
,
document_id
integer
NOT NULL
,
access
integer
NOT NULL
,
date
date
NOT NULL
,
occurrences
text
);
--
--
Name: featured_reports; Type: TABLE; Schema: public; Owner: -; Tablespace:
--
CREATE
TABLE
featured_reports
(
id
integer
NOT NULL
,
url
character varying
(
255
)
NOT NULL
,
title
character varying
(
255
)
NOT NULL
,
organization
character varying
(
255
)
NOT NULL
,
article_date
date
NOT NULL
,
writeup
text
NOT NULL
,
present_order
integer
DEFAULT
0
NOT NULL
,
created_at
timestamp without time zone
,
updated_at
timestamp without time zone
);
--
--
Name: featured_reports_id_seq; Type: SEQUENCE; Schema: public; Owner: -
--
CREATE
SEQUENCE
featured_reports_id_seq
START WITH
1
INCREMENT BY
1
NO MINVALUE
NO MAXVALUE
CACHE
1
;
--
--
Name: featured_reports_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: -
--
ALTER
SEQUENCE
featured_reports_id_seq OWNED BY
featured_reports
.
id
;
--
--
Name: projects; Type: TABLE; Schema: public; Owner: -; Tablespace:
--
CREATE
TABLE
projects
(
id
integer
NOT NULL
,
account_id
integer
,
title
character varying
(
255
),
description
text
,
hidden
boolean
DEFAULT false
NOT NULL
);
--
--
Name: labels_id_seq; Type: SEQUENCE; Schema: public; Owner: -
--
CREATE
SEQUENCE
labels_id_seq
START WITH
1
INCREMENT BY
1
NO MINVALUE
NO MAXVALUE
CACHE
1
;
--
--
Name: labels_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: -
--
ALTER
SEQUENCE
labels_id_seq OWNED BY
projects
.
id
;
--
--
Name: memberships; Type: TABLE; Schema: public; Owner: -; Tablespace:
--
CREATE
TABLE
memberships
(
id
integer
NOT NULL
,
organization_id
integer
NOT NULL
,
account_id
integer
NOT NULL
,
role
integer
NOT NULL
,
"
default
"
boolean
DEFAULT false,
concealed
boolean
DEFAULT false
);
--
--
Name: memberships_id_seq; Type: SEQUENCE; Schema: public; Owner: -
--
CREATE
SEQUENCE
memberships_id_seq
START WITH
1
INCREMENT BY
1
NO MINVALUE
NO MAXVALUE
CACHE
1
;
View remainder of file in raw view
Back
|
FazBrowse Home
|
New Git URL