-
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathWebPhonon.sql
More file actions
879 lines (610 loc) · 19.7 KB
/
WebPhonon.sql
File metadata and controls
879 lines (610 loc) · 19.7 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
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
--
-- PostgreSQL database dump
--
-- Dumped from database version 9.4.5
-- Dumped by pg_dump version 9.4.5
-- Started on 2016-02-12 20:47:27 IST
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;
DROP DATABASE webphonon;
--
-- TOC entry 2744 (class 1262 OID 16404)
-- Name: webphonon; Type: DATABASE; Schema: -; Owner: postgres
--
CREATE DATABASE webphonon WITH TEMPLATE = template0 ENCODING = 'UTF8' LC_COLLATE = 'en_US.UTF-8' LC_CTYPE = 'en_US.UTF-8';
ALTER DATABASE webphonon OWNER TO postgres;
\connect webphonon
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;
--
-- TOC entry 5 (class 2615 OID 2200)
-- Name: public; Type: SCHEMA; Schema: -; Owner: postgres
--
CREATE SCHEMA public;
ALTER SCHEMA public OWNER TO postgres;
--
-- TOC entry 2745 (class 0 OID 0)
-- Dependencies: 5
-- Name: SCHEMA public; Type: COMMENT; Schema: -; Owner: postgres
--
COMMENT ON SCHEMA public IS 'standard public schema';
--
-- TOC entry 198 (class 3079 OID 12467)
-- Name: plpgsql; Type: EXTENSION; Schema: -; Owner:
--
CREATE EXTENSION IF NOT EXISTS plpgsql WITH SCHEMA pg_catalog;
--
-- TOC entry 2747 (class 0 OID 0)
-- Dependencies: 198
-- Name: EXTENSION plpgsql; Type: COMMENT; Schema: -; Owner:
--
COMMENT ON EXTENSION plpgsql IS 'PL/pgSQL procedural language';
--
-- TOC entry 199 (class 3079 OID 16393)
-- Name: fuzzystrmatch; Type: EXTENSION; Schema: -; Owner:
--
CREATE EXTENSION IF NOT EXISTS fuzzystrmatch WITH SCHEMA public;
--
-- TOC entry 2748 (class 0 OID 0)
-- Dependencies: 199
-- Name: EXTENSION fuzzystrmatch; Type: COMMENT; Schema: -; Owner:
--
COMMENT ON EXTENSION fuzzystrmatch IS 'determine similarities and distance between strings';
SET search_path = public, pg_catalog;
SET default_tablespace = '';
SET default_with_oids = true;
--
-- TOC entry 173 (class 1259 OID 16481)
-- Name: actor; Type: TABLE; Schema: public; Owner: postgres; Tablespace:
--
CREATE TABLE actor (
actor_id integer NOT NULL,
name character varying
);
ALTER TABLE actor OWNER TO postgres;
--
-- TOC entry 172 (class 1259 OID 16479)
-- Name: actor_actor_id_seq; Type: SEQUENCE; Schema: public; Owner: postgres
--
CREATE SEQUENCE actor_actor_id_seq
START WITH 1
INCREMENT BY 1
NO MINVALUE
NO MAXVALUE
CACHE 1;
ALTER TABLE actor_actor_id_seq OWNER TO postgres;
--
-- TOC entry 2749 (class 0 OID 0)
-- Dependencies: 172
-- Name: actor_actor_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: postgres
--
ALTER SEQUENCE actor_actor_id_seq OWNED BY actor.actor_id;
--
-- TOC entry 175 (class 1259 OID 16495)
-- Name: album; Type: TABLE; Schema: public; Owner: postgres; Tablespace:
--
CREATE TABLE album (
album_id integer NOT NULL,
album_name character varying,
record_label character varying
);
ALTER TABLE album OWNER TO postgres;
--
-- TOC entry 174 (class 1259 OID 16493)
-- Name: album_album_id_seq; Type: SEQUENCE; Schema: public; Owner: postgres
--
CREATE SEQUENCE album_album_id_seq
START WITH 1
INCREMENT BY 1
NO MINVALUE
NO MAXVALUE
CACHE 1;
ALTER TABLE album_album_id_seq OWNER TO postgres;
--
-- TOC entry 2750 (class 0 OID 0)
-- Dependencies: 174
-- Name: album_album_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: postgres
--
ALTER SEQUENCE album_album_id_seq OWNED BY album.album_id;
--
-- TOC entry 177 (class 1259 OID 16510)
-- Name: album_cast; Type: TABLE; Schema: public; Owner: postgres; Tablespace:
--
CREATE TABLE album_cast (
album_cast_id integer NOT NULL,
album_id integer,
artist_id integer,
role character varying
);
ALTER TABLE album_cast OWNER TO postgres;
--
-- TOC entry 176 (class 1259 OID 16508)
-- Name: album_cast_album_cast_id_seq; Type: SEQUENCE; Schema: public; Owner: postgres
--
CREATE SEQUENCE album_cast_album_cast_id_seq
START WITH 1
INCREMENT BY 1
NO MINVALUE
NO MAXVALUE
CACHE 1;
ALTER TABLE album_cast_album_cast_id_seq OWNER TO postgres;
--
-- TOC entry 2751 (class 0 OID 0)
-- Dependencies: 176
-- Name: album_cast_album_cast_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: postgres
--
ALTER SEQUENCE album_cast_album_cast_id_seq OWNED BY album_cast.album_cast_id;
--
-- TOC entry 179 (class 1259 OID 16526)
-- Name: artist; Type: TABLE; Schema: public; Owner: postgres; Tablespace:
--
CREATE TABLE artist (
artist_id integer NOT NULL,
name character varying
);
ALTER TABLE artist OWNER TO postgres;
--
-- TOC entry 178 (class 1259 OID 16524)
-- Name: artist_artist_id_seq; Type: SEQUENCE; Schema: public; Owner: postgres
--
CREATE SEQUENCE artist_artist_id_seq
START WITH 1
INCREMENT BY 1
NO MINVALUE
NO MAXVALUE
CACHE 1;
ALTER TABLE artist_artist_id_seq OWNER TO postgres;
--
-- TOC entry 2752 (class 0 OID 0)
-- Dependencies: 178
-- Name: artist_artist_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: postgres
--
ALTER SEQUENCE artist_artist_id_seq OWNED BY artist.artist_id;
--
-- TOC entry 181 (class 1259 OID 16540)
-- Name: movie_cast; Type: TABLE; Schema: public; Owner: postgres; Tablespace:
--
CREATE TABLE movie_cast (
movie_cast_id integer NOT NULL,
movie_id integer,
actor_id integer,
charecter_name character varying,
role character varying
);
ALTER TABLE movie_cast OWNER TO postgres;
--
-- TOC entry 180 (class 1259 OID 16538)
-- Name: movie_cast_movie_cast_id_seq; Type: SEQUENCE; Schema: public; Owner: postgres
--
CREATE SEQUENCE movie_cast_movie_cast_id_seq
START WITH 1
INCREMENT BY 1
NO MINVALUE
NO MAXVALUE
CACHE 1;
ALTER TABLE movie_cast_movie_cast_id_seq OWNER TO postgres;
--
-- TOC entry 2753 (class 0 OID 0)
-- Dependencies: 180
-- Name: movie_cast_movie_cast_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: postgres
--
ALTER SEQUENCE movie_cast_movie_cast_id_seq OWNED BY movie_cast.movie_cast_id;
--
-- TOC entry 183 (class 1259 OID 16557)
-- Name: movies; Type: TABLE; Schema: public; Owner: postgres; Tablespace:
--
CREATE TABLE movies (
movies_id integer NOT NULL,
url text NOT NULL,
title character varying,
language character varying,
studio character varying,
rating character varying,
genre character varying,
year integer
);
ALTER TABLE movies OWNER TO postgres;
--
-- TOC entry 182 (class 1259 OID 16555)
-- Name: movies_movies_id_seq; Type: SEQUENCE; Schema: public; Owner: postgres
--
CREATE SEQUENCE movies_movies_id_seq
START WITH 1
INCREMENT BY 1
NO MINVALUE
NO MAXVALUE
CACHE 1;
ALTER TABLE movies_movies_id_seq OWNER TO postgres;
--
-- TOC entry 2754 (class 0 OID 0)
-- Dependencies: 182
-- Name: movies_movies_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: postgres
--
ALTER SEQUENCE movies_movies_id_seq OWNED BY movies.movies_id;
--
-- TOC entry 185 (class 1259 OID 16579)
-- Name: music; Type: TABLE; Schema: public; Owner: postgres; Tablespace:
--
CREATE TABLE music (
music_id integer NOT NULL,
url text NOT NULL,
title character varying,
genre character varying,
language character varying
);
ALTER TABLE music OWNER TO postgres;
--
-- TOC entry 187 (class 1259 OID 16598)
-- Name: music_album; Type: TABLE; Schema: public; Owner: postgres; Tablespace:
--
CREATE TABLE music_album (
music_album_id integer NOT NULL,
album_id integer,
music_id integer,
track integer
);
ALTER TABLE music_album OWNER TO postgres;
--
-- TOC entry 186 (class 1259 OID 16596)
-- Name: music_album_music_album_id_seq; Type: SEQUENCE; Schema: public; Owner: postgres
--
CREATE SEQUENCE music_album_music_album_id_seq
START WITH 1
INCREMENT BY 1
NO MINVALUE
NO MAXVALUE
CACHE 1;
ALTER TABLE music_album_music_album_id_seq OWNER TO postgres;
--
-- TOC entry 2755 (class 0 OID 0)
-- Dependencies: 186
-- Name: music_album_music_album_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: postgres
--
ALTER SEQUENCE music_album_music_album_id_seq OWNED BY music_album.music_album_id;
--
-- TOC entry 184 (class 1259 OID 16577)
-- Name: music_music_id_seq; Type: SEQUENCE; Schema: public; Owner: postgres
--
CREATE SEQUENCE music_music_id_seq
START WITH 1
INCREMENT BY 1
NO MINVALUE
NO MAXVALUE
CACHE 1;
ALTER TABLE music_music_id_seq OWNER TO postgres;
--
-- TOC entry 2756 (class 0 OID 0)
-- Dependencies: 184
-- Name: music_music_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: postgres
--
ALTER SEQUENCE music_music_id_seq OWNED BY music.music_id;
--
-- TOC entry 189 (class 1259 OID 16611)
-- Name: music_video_cast; Type: TABLE; Schema: public; Owner: postgres; Tablespace:
--
CREATE TABLE music_video_cast (
music_video_cast_id integer NOT NULL,
music_video_id integer,
actor_id integer
);
ALTER TABLE music_video_cast OWNER TO postgres;
--
-- TOC entry 188 (class 1259 OID 16609)
-- Name: music_video_cast_music_video_cast_id_seq; Type: SEQUENCE; Schema: public; Owner: postgres
--
CREATE SEQUENCE music_video_cast_music_video_cast_id_seq
START WITH 1
INCREMENT BY 1
NO MINVALUE
NO MAXVALUE
CACHE 1;
ALTER TABLE music_video_cast_music_video_cast_id_seq OWNER TO postgres;
--
-- TOC entry 2757 (class 0 OID 0)
-- Dependencies: 188
-- Name: music_video_cast_music_video_cast_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: postgres
--
ALTER SEQUENCE music_video_cast_music_video_cast_id_seq OWNED BY music_video_cast.music_video_cast_id;
--
-- TOC entry 191 (class 1259 OID 16623)
-- Name: music_videos; Type: TABLE; Schema: public; Owner: postgres; Tablespace:
--
CREATE TABLE music_videos (
mv_id integer NOT NULL,
url text NOT NULL,
music_id integer
);
ALTER TABLE music_videos OWNER TO postgres;
--
-- TOC entry 190 (class 1259 OID 16621)
-- Name: music_videos_mv_id_seq; Type: SEQUENCE; Schema: public; Owner: postgres
--
CREATE SEQUENCE music_videos_mv_id_seq
START WITH 1
INCREMENT BY 1
NO MINVALUE
NO MAXVALUE
CACHE 1;
ALTER TABLE music_videos_mv_id_seq OWNER TO postgres;
--
-- TOC entry 2758 (class 0 OID 0)
-- Dependencies: 190
-- Name: music_videos_mv_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: postgres
--
ALTER SEQUENCE music_videos_mv_id_seq OWNED BY music_videos.mv_id;
--
-- TOC entry 193 (class 1259 OID 16640)
-- Name: music_view; Type: TABLE; Schema: public; Owner: postgres; Tablespace:
--
CREATE TABLE music_view (
music_video_cast_id integer NOT NULL,
music_id integer,
actor_id integer
);
ALTER TABLE music_view OWNER TO postgres;
--
-- TOC entry 192 (class 1259 OID 16638)
-- Name: music_view_music_video_cast_id_seq; Type: SEQUENCE; Schema: public; Owner: postgres
--
CREATE SEQUENCE music_view_music_video_cast_id_seq
START WITH 1
INCREMENT BY 1
NO MINVALUE
NO MAXVALUE
CACHE 1;
ALTER TABLE music_view_music_video_cast_id_seq OWNER TO postgres;
--
-- TOC entry 2759 (class 0 OID 0)
-- Dependencies: 192
-- Name: music_view_music_video_cast_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: postgres
--
ALTER SEQUENCE music_view_music_video_cast_id_seq OWNED BY music_view.music_video_cast_id;
--
-- TOC entry 195 (class 1259 OID 16652)
-- Name: tv; Type: TABLE; Schema: public; Owner: postgres; Tablespace:
--
CREATE TABLE tv (
tv_id integer NOT NULL,
url text NOT NULL,
title character varying,
season integer,
episode integer,
ep_title character varying,
language character varying,
genre character varying
);
ALTER TABLE tv OWNER TO postgres;
--
-- TOC entry 197 (class 1259 OID 16674)
-- Name: tv_cast; Type: TABLE; Schema: public; Owner: postgres; Tablespace:
--
CREATE TABLE tv_cast (
tv_cast_id integer NOT NULL,
tv_id integer,
actor_id integer,
charecter_name character varying,
role character varying
);
ALTER TABLE tv_cast OWNER TO postgres;
--
-- TOC entry 196 (class 1259 OID 16672)
-- Name: tv_cast_tv_cast_id_seq; Type: SEQUENCE; Schema: public; Owner: postgres
--
CREATE SEQUENCE tv_cast_tv_cast_id_seq
START WITH 1
INCREMENT BY 1
NO MINVALUE
NO MAXVALUE
CACHE 1;
ALTER TABLE tv_cast_tv_cast_id_seq OWNER TO postgres;
--
-- TOC entry 2760 (class 0 OID 0)
-- Dependencies: 196
-- Name: tv_cast_tv_cast_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: postgres
--
ALTER SEQUENCE tv_cast_tv_cast_id_seq OWNED BY tv_cast.tv_cast_id;
--
-- TOC entry 194 (class 1259 OID 16650)
-- Name: tv_tv_id_seq; Type: SEQUENCE; Schema: public; Owner: postgres
--
CREATE SEQUENCE tv_tv_id_seq
START WITH 1
INCREMENT BY 1
NO MINVALUE
NO MAXVALUE
CACHE 1;
ALTER TABLE tv_tv_id_seq OWNER TO postgres;
--
-- TOC entry 2761 (class 0 OID 0)
-- Dependencies: 194
-- Name: tv_tv_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: postgres
--
ALTER SEQUENCE tv_tv_id_seq OWNED BY tv.tv_id;
--
-- TOC entry 2584 (class 2604 OID 16484)
-- Name: actor_id; Type: DEFAULT; Schema: public; Owner: postgres
--
ALTER TABLE ONLY actor ALTER COLUMN actor_id SET DEFAULT nextval('actor_actor_id_seq'::regclass);
--
-- TOC entry 2585 (class 2604 OID 16498)
-- Name: album_id; Type: DEFAULT; Schema: public; Owner: postgres
--
ALTER TABLE ONLY album ALTER COLUMN album_id SET DEFAULT nextval('album_album_id_seq'::regclass);
--
-- TOC entry 2586 (class 2604 OID 16513)
-- Name: album_cast_id; Type: DEFAULT; Schema: public; Owner: postgres
--
ALTER TABLE ONLY album_cast ALTER COLUMN album_cast_id SET DEFAULT nextval('album_cast_album_cast_id_seq'::regclass);
--
-- TOC entry 2587 (class 2604 OID 16529)
-- Name: artist_id; Type: DEFAULT; Schema: public; Owner: postgres
--
ALTER TABLE ONLY artist ALTER COLUMN artist_id SET DEFAULT nextval('artist_artist_id_seq'::regclass);
--
-- TOC entry 2588 (class 2604 OID 16543)
-- Name: movie_cast_id; Type: DEFAULT; Schema: public; Owner: postgres
--
ALTER TABLE ONLY movie_cast ALTER COLUMN movie_cast_id SET DEFAULT nextval('movie_cast_movie_cast_id_seq'::regclass);
--
-- TOC entry 2589 (class 2604 OID 16560)
-- Name: movies_id; Type: DEFAULT; Schema: public; Owner: postgres
--
ALTER TABLE ONLY movies ALTER COLUMN movies_id SET DEFAULT nextval('movies_movies_id_seq'::regclass);
--
-- TOC entry 2590 (class 2604 OID 16582)
-- Name: music_id; Type: DEFAULT; Schema: public; Owner: postgres
--
ALTER TABLE ONLY music ALTER COLUMN music_id SET DEFAULT nextval('music_music_id_seq'::regclass);
--
-- TOC entry 2591 (class 2604 OID 16601)
-- Name: music_album_id; Type: DEFAULT; Schema: public; Owner: postgres
--
ALTER TABLE ONLY music_album ALTER COLUMN music_album_id SET DEFAULT nextval('music_album_music_album_id_seq'::regclass);
--
-- TOC entry 2592 (class 2604 OID 16614)
-- Name: music_video_cast_id; Type: DEFAULT; Schema: public; Owner: postgres
--
ALTER TABLE ONLY music_video_cast ALTER COLUMN music_video_cast_id SET DEFAULT nextval('music_video_cast_music_video_cast_id_seq'::regclass);
--
-- TOC entry 2593 (class 2604 OID 16626)
-- Name: mv_id; Type: DEFAULT; Schema: public; Owner: postgres
--
ALTER TABLE ONLY music_videos ALTER COLUMN mv_id SET DEFAULT nextval('music_videos_mv_id_seq'::regclass);
--
-- TOC entry 2594 (class 2604 OID 16643)
-- Name: music_video_cast_id; Type: DEFAULT; Schema: public; Owner: postgres
--
ALTER TABLE ONLY music_view ALTER COLUMN music_video_cast_id SET DEFAULT nextval('music_view_music_video_cast_id_seq'::regclass);
--
-- TOC entry 2595 (class 2604 OID 16655)
-- Name: tv_id; Type: DEFAULT; Schema: public; Owner: postgres
--
ALTER TABLE ONLY tv ALTER COLUMN tv_id SET DEFAULT nextval('tv_tv_id_seq'::regclass);
--
-- TOC entry 2596 (class 2604 OID 16677)
-- Name: tv_cast_id; Type: DEFAULT; Schema: public; Owner: postgres
--
ALTER TABLE ONLY tv_cast ALTER COLUMN tv_cast_id SET DEFAULT nextval('tv_cast_tv_cast_id_seq'::regclass);
--
-- TOC entry 2598 (class 2606 OID 16489)
-- Name: actor_pkey; Type: CONSTRAINT; Schema: public; Owner: postgres; Tablespace:
--
ALTER TABLE ONLY actor
ADD CONSTRAINT actor_pkey PRIMARY KEY (actor_id);
--
-- TOC entry 2602 (class 2606 OID 16518)
-- Name: album_cast_pkey; Type: CONSTRAINT; Schema: public; Owner: postgres; Tablespace:
--
ALTER TABLE ONLY album_cast
ADD CONSTRAINT album_cast_pkey PRIMARY KEY (album_cast_id);
--
-- TOC entry 2600 (class 2606 OID 16503)
-- Name: album_pkey; Type: CONSTRAINT; Schema: public; Owner: postgres; Tablespace:
--
ALTER TABLE ONLY album
ADD CONSTRAINT album_pkey PRIMARY KEY (album_id);
--
-- TOC entry 2604 (class 2606 OID 16534)
-- Name: artist_pkey; Type: CONSTRAINT; Schema: public; Owner: postgres; Tablespace:
--
ALTER TABLE ONLY artist
ADD CONSTRAINT artist_pkey PRIMARY KEY (artist_id);
--
-- TOC entry 2606 (class 2606 OID 16548)
-- Name: movie_cast_pkey; Type: CONSTRAINT; Schema: public; Owner: postgres; Tablespace:
--
ALTER TABLE ONLY movie_cast
ADD CONSTRAINT movie_cast_pkey PRIMARY KEY (movie_cast_id);
--
-- TOC entry 2608 (class 2606 OID 16565)
-- Name: movies_pkey; Type: CONSTRAINT; Schema: public; Owner: postgres; Tablespace:
--
ALTER TABLE ONLY movies
ADD CONSTRAINT movies_pkey PRIMARY KEY (movies_id);
--
-- TOC entry 2610 (class 2606 OID 16567)
-- Name: movies_url_key; Type: CONSTRAINT; Schema: public; Owner: postgres; Tablespace:
--
ALTER TABLE ONLY movies
ADD CONSTRAINT movies_url_key UNIQUE (url);
--
-- TOC entry 2616 (class 2606 OID 16603)
-- Name: music_album_pkey; Type: CONSTRAINT; Schema: public; Owner: postgres; Tablespace:
--
ALTER TABLE ONLY music_album
ADD CONSTRAINT music_album_pkey PRIMARY KEY (music_album_id);
--
-- TOC entry 2612 (class 2606 OID 16587)
-- Name: music_pkey; Type: CONSTRAINT; Schema: public; Owner: postgres; Tablespace:
--
ALTER TABLE ONLY music
ADD CONSTRAINT music_pkey PRIMARY KEY (music_id);
--
-- TOC entry 2614 (class 2606 OID 16589)
-- Name: music_url_key; Type: CONSTRAINT; Schema: public; Owner: postgres; Tablespace:
--
ALTER TABLE ONLY music
ADD CONSTRAINT music_url_key UNIQUE (url);
--
-- TOC entry 2618 (class 2606 OID 16616)
-- Name: music_video_cast_pkey; Type: CONSTRAINT; Schema: public; Owner: postgres; Tablespace:
--
ALTER TABLE ONLY music_video_cast
ADD CONSTRAINT music_video_cast_pkey PRIMARY KEY (music_video_cast_id);
--
-- TOC entry 2620 (class 2606 OID 16631)
-- Name: music_videos_pkey; Type: CONSTRAINT; Schema: public; Owner: postgres; Tablespace:
--
ALTER TABLE ONLY music_videos
ADD CONSTRAINT music_videos_pkey PRIMARY KEY (mv_id);
--
-- TOC entry 2622 (class 2606 OID 16633)
-- Name: music_videos_url_key; Type: CONSTRAINT; Schema: public; Owner: postgres; Tablespace:
--
ALTER TABLE ONLY music_videos
ADD CONSTRAINT music_videos_url_key UNIQUE (url);
--
-- TOC entry 2624 (class 2606 OID 16645)
-- Name: music_view_pkey; Type: CONSTRAINT; Schema: public; Owner: postgres; Tablespace:
--
ALTER TABLE ONLY music_view
ADD CONSTRAINT music_view_pkey PRIMARY KEY (music_video_cast_id);
--
-- TOC entry 2630 (class 2606 OID 16682)
-- Name: tv_cast_pkey; Type: CONSTRAINT; Schema: public; Owner: postgres; Tablespace:
--
ALTER TABLE ONLY tv_cast
ADD CONSTRAINT tv_cast_pkey PRIMARY KEY (tv_cast_id);
--
-- TOC entry 2626 (class 2606 OID 16660)
-- Name: tv_pkey; Type: CONSTRAINT; Schema: public; Owner: postgres; Tablespace:
--
ALTER TABLE ONLY tv
ADD CONSTRAINT tv_pkey PRIMARY KEY (tv_id);
--
-- TOC entry 2628 (class 2606 OID 16662)
-- Name: tv_url_key; Type: CONSTRAINT; Schema: public; Owner: postgres; Tablespace:
--
ALTER TABLE ONLY tv
ADD CONSTRAINT tv_url_key UNIQUE (url);
--
-- TOC entry 2746 (class 0 OID 0)
-- Dependencies: 5
-- Name: public; Type: ACL; Schema: -; Owner: postgres
--
REVOKE ALL ON SCHEMA public FROM PUBLIC;
REVOKE ALL ON SCHEMA public FROM postgres;
GRANT ALL ON SCHEMA public TO postgres;
GRANT ALL ON SCHEMA public TO PUBLIC;
-- Completed on 2016-02-12 20:47:27 IST
--
-- PostgreSQL database dump complete
--