Project

General

Profile

« Previous | Next » 

Revision 904

VegBIEN: Renamed locationplace to locationdetermination

View differences:

vegbien.sql
1365 1365

  
1366 1366

  
1367 1367
--
1368
-- Name: locationplace; Type: TABLE; Schema: public; Owner: -; Tablespace: 
1368
-- Name: locationdetermination; Type: TABLE; Schema: public; Owner: -; Tablespace: 
1369 1369
--
1370 1370

  
1371
CREATE TABLE locationplace (
1372
    locationplace_id integer NOT NULL,
1371
CREATE TABLE locationdetermination (
1372
    locationdetermination_id integer NOT NULL,
1373 1373
    location_id integer NOT NULL,
1374 1374
    calculated boolean,
1375 1375
    namedplace_id integer NOT NULL
......
1377 1377

  
1378 1378

  
1379 1379
--
1380
-- Name: locationplace_locationplace_id_seq; Type: SEQUENCE; Schema: public; Owner: -
1380
-- Name: locationdetermination_locationdetermination_id_seq; Type: SEQUENCE; Schema: public; Owner: -
1381 1381
--
1382 1382

  
1383
CREATE SEQUENCE locationplace_locationplace_id_seq
1383
CREATE SEQUENCE locationdetermination_locationdetermination_id_seq
1384 1384
    START WITH 1
1385 1385
    INCREMENT BY 1
1386 1386
    NO MINVALUE
......
1389 1389

  
1390 1390

  
1391 1391
--
1392
-- Name: locationplace_locationplace_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: -
1392
-- Name: locationdetermination_locationdetermination_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: -
1393 1393
--
1394 1394

  
1395
ALTER SEQUENCE locationplace_locationplace_id_seq OWNED BY locationplace.locationplace_id;
1395
ALTER SEQUENCE locationdetermination_locationdetermination_id_seq OWNED BY locationdetermination.locationdetermination_id;
1396 1396

  
1397 1397

  
1398 1398
--
......
3613 3613

  
3614 3614

  
3615 3615
--
3616
-- Name: locationplace_id; Type: DEFAULT; Schema: public; Owner: -
3616
-- Name: locationdetermination_id; Type: DEFAULT; Schema: public; Owner: -
3617 3617
--
3618 3618

  
3619
ALTER TABLE locationplace ALTER COLUMN locationplace_id SET DEFAULT nextval('locationplace_locationplace_id_seq'::regclass);
3619
ALTER TABLE locationdetermination ALTER COLUMN locationdetermination_id SET DEFAULT nextval('locationdetermination_locationdetermination_id_seq'::regclass);
3620 3620

  
3621 3621

  
3622 3622
--
......
4342 4342

  
4343 4343

  
4344 4344
--
4345
-- Name: locationplace_keys; Type: CONSTRAINT; Schema: public; Owner: -; Tablespace: 
4345
-- Name: locationdetermination_keys; Type: CONSTRAINT; Schema: public; Owner: -; Tablespace: 
4346 4346
--
4347 4347

  
4348
ALTER TABLE ONLY locationplace
4349
    ADD CONSTRAINT locationplace_keys UNIQUE (location_id, namedplace_id);
4348
ALTER TABLE ONLY locationdetermination
4349
    ADD CONSTRAINT locationdetermination_keys UNIQUE (location_id, namedplace_id);
4350 4350

  
4351 4351

  
4352 4352
--
4353
-- Name: locationplace_pkey; Type: CONSTRAINT; Schema: public; Owner: -; Tablespace: 
4353
-- Name: locationdetermination_pkey; Type: CONSTRAINT; Schema: public; Owner: -; Tablespace: 
4354 4354
--
4355 4355

  
4356
ALTER TABLE ONLY locationplace
4357
    ADD CONSTRAINT locationplace_pkey PRIMARY KEY (locationplace_id);
4356
ALTER TABLE ONLY locationdetermination
4357
    ADD CONSTRAINT locationdetermination_pkey PRIMARY KEY (locationdetermination_id);
4358 4358

  
4359 4359

  
4360 4360
--
......
5488 5488

  
5489 5489

  
5490 5490
--
5491
-- Name: locationplace_location_id_x; Type: INDEX; Schema: public; Owner: -; Tablespace: 
5491
-- Name: locationdetermination_location_id_x; Type: INDEX; Schema: public; Owner: -; Tablespace: 
5492 5492
--
5493 5493

  
5494
CREATE INDEX locationplace_location_id_x ON locationplace USING btree (location_id);
5494
CREATE INDEX locationdetermination_location_id_x ON locationdetermination USING btree (location_id);
5495 5495

  
5496 5496

  
5497 5497
--
5498
-- Name: locationplace_namedplace_id_x; Type: INDEX; Schema: public; Owner: -; Tablespace: 
5498
-- Name: locationdetermination_namedplace_id_x; Type: INDEX; Schema: public; Owner: -; Tablespace: 
5499 5499
--
5500 5500

  
5501
CREATE INDEX locationplace_namedplace_id_x ON locationplace USING btree (namedplace_id);
5501
CREATE INDEX locationdetermination_namedplace_id_x ON locationdetermination USING btree (namedplace_id);
5502 5502

  
5503 5503

  
5504 5504
--
......
6560 6560

  
6561 6561

  
6562 6562
--
6563
-- Name: locationplace_location_id; Type: FK CONSTRAINT; Schema: public; Owner: -
6563
-- Name: locationdetermination_location_id; Type: FK CONSTRAINT; Schema: public; Owner: -
6564 6564
--
6565 6565

  
6566
ALTER TABLE ONLY locationplace
6567
    ADD CONSTRAINT locationplace_location_id FOREIGN KEY (location_id) REFERENCES location(location_id) ON UPDATE CASCADE ON DELETE CASCADE;
6566
ALTER TABLE ONLY locationdetermination
6567
    ADD CONSTRAINT locationdetermination_location_id FOREIGN KEY (location_id) REFERENCES location(location_id) ON UPDATE CASCADE ON DELETE CASCADE;
6568 6568

  
6569 6569

  
6570 6570
--
6571
-- Name: locationplace_namedplace_id; Type: FK CONSTRAINT; Schema: public; Owner: -
6571
-- Name: locationdetermination_namedplace_id; Type: FK CONSTRAINT; Schema: public; Owner: -
6572 6572
--
6573 6573

  
6574
ALTER TABLE ONLY locationplace
6575
    ADD CONSTRAINT locationplace_namedplace_id FOREIGN KEY (namedplace_id) REFERENCES namedplace(namedplace_id) ON UPDATE CASCADE ON DELETE CASCADE;
6574
ALTER TABLE ONLY locationdetermination
6575
    ADD CONSTRAINT locationdetermination_namedplace_id FOREIGN KEY (namedplace_id) REFERENCES namedplace(namedplace_id) ON UPDATE CASCADE ON DELETE CASCADE;
6576 6576

  
6577 6577

  
6578 6578
--

Also available in: Unified diff