pggeodb.nancy.inra.fr/db_woodseer - db_woodseer on pggeodb.nancy.inra.fr
Previous topic Chapter index Next topic

Table: t_measure_macq

 

 

Schema

public

 

Owner

woodseer

 

Tablespace

(default)

 

Descriptions

Table of measurements of acquisitions

 

Fields

PK

FK

Name

Data type

Not null

Unique

Inherited

Default

Description

 

macq_id

serial

 

nextval('t_measure_macq_macq_id_seq'::regclass)

Digital automatic identifier of the acquisition measurement

 

macq_acq_id

integer

 

 

 

Identifier of the corresponding singularity detection

 

macq_var_id

integer

 

 

 

Identifier of the corresponding variable measured

 

macq_uni_id

integer

 

 

 

 

Identifier of the corresponding unit of the variable measured

 

macq_fil_id

integer

 

 

 

Identifier of the file in which the measurement has been provided

 

macq_std_id

integer

 

 

 

 

Identifier of the associated standard to the measurement

 

macq_tym_id

integer

 

 

 

 

Identifier of the type of measurement

 

macq_prot_id

integer

 

 

 

 

Identifier of the protocol applied for the measurement

 

 

macq_value_num

double precision

 

 

 

 

value of the measurement if numeric type

 

 

macq_value_text

varchar

 

 

 

 

value of the measurement if text type

 

 

macq_value_date

date

 

 

 

 

value of the measure if it is a date type

 

 

macq_date_measure

date

 

 

 

 

date of the measure

 

 

macq_precision_date_measure

double precision

 

 

 

 

Accuracy of the date of the measurement

 

 

macq_precision_measure

double precision

 

 

 

 

Acuracy of the measurement

 

 

macq_observation

varchar(255)

 

 

 

 

Additional information about the measurement

 

Foreign Keys

Name

Fields

FK Table

FK Fields

Delete Action

Update Action

Deferrable

Check Time

Description

c_fk_acq_macq

macq_acq_id

public.t_acquisition_acq

acq_id

No Action

No Action

 

Immediate

a measure must be attached to one and only one acquisition

c_fk_fil_macq

macq_fil_id

public.tr_file_fil

fil_id

No Action

No Action

 

Immediate

a measure can be attached to O or 1 file

c_fk_prot_macq

macq_prot_id

public.tr_protocol_prot

prot_id

No Action

No Action

 

Immediate

a measure can be attached to O or 1 protocol

c_fk_std_macq

macq_std_id

public.tr_standard_std

std_id

No Action

No Action

 

Immediate

a measure can be attached to O or 1 unit

c_fk_tym_macq

macq_tym_id

public.tr_type_measure_tym

tym_id

No Action

No Action

 

Immediate

a measure can be attached to O or 1 type of measure

c_fk_uni_macq

macq_uni_id

public.tr_unit_uni

uni_id

No Action

No Action

 

Immediate

a measure can be attached to O or 1 unit

c_fk_var_macq

macq_var_id

public.tr_variable_var

var_id

No Action

No Action

 

Immediate

a measure must be attached to one and only one variable

 

Check Constraints

There are no check constraints for table t_measure_macq

 

Indices

Name

Type

Function

Fields

Primary Key

Unique

Description

c_uni_acq_var_datemeasure_macq

btree

 

macq_acq_id, macq_var_id, macq_date_measure

 

The set identifier of the acquisition / identifier of the variable / date of the measure is unique

c_uni_acq_var_macq

btree

 

macq_acq_id, macq_var_id

 

The variable / acquisition pair is unique if the measure date is not entered.

t_measure_macq_pkey

btree

 

macq_id

 

x_btr_fkey_acq_macq

btree

 

macq_acq_id

 

 

Foreign key index to speed up updates / deletion

x_btr_fkey_fil_macq

btree

 

macq_fil_id

 

 

Foreign key index to speed up updates / deletion

x_btr_fkey_prot_macq

btree

 

macq_prot_id

 

 

Foreign key index to speed up updates / deletion

x_btr_fkey_std_macq

btree

 

macq_std_id

 

 

Foreign key index to speed up updates / deletion

x_btr_fkey_tym_macq

btree

 

macq_tym_id

 

 

Foreign key index to speed up updates / deletion

x_btr_fkey_uni_macq

btree

 

macq_uni_id

 

 

Foreign key index to speed up updates / deletion

x_btr_fkey_var_macq

btree

 

macq_var_id

 

 

Foreign key index to speed up updates / deletion

 

Triggers

There are no triggers for table t_measure_macq

 

Rules

There are no rules for table t_measure_macq

 

Policies

There are no policies for table t_measure_macq

 

Referenced

Table

Schema

Foreign Key

Fields

FK Table

FK Fields

Delete Action

Update Action

Deferrable

Check Time

Description

tj_rol_ope_macq_romacq

public

c_fk_macq_romacq

romacq_macq_id

public.t_measure_macq

macq_id

No Action

No Action

 

Immediate

The rom_macq_id field necessarily corresponds to an existing measure

 

Properties

Property

Value

Inherited From

 

Rows

0

Pages

0

System

 

Temporary

 

With OID

 

Definition

CREATE TABLE public.t_measure_macq (
 macq_id SERIAL,
 macq_acq_id INTEGER NOT NULL,
 macq_var_id INTEGER NOT NULL,
 macq_uni_id INTEGER,
 macq_fil_id INTEGER NOT NULL,
 macq_std_id INTEGER,
 macq_tym_id INTEGER,
 macq_prot_id INTEGER,
 macq_value_num DOUBLE PRECISION,
 macq_value_text VARCHAR,
 macq_value_date DATE,
 macq_date_measure DATE,
 macq_precision_date_measure DOUBLE PRECISION,
 macq_precision_measure DOUBLE PRECISION,
 macq_observation VARCHAR(255),
 CONSTRAINT c_uni_acq_var_datemeasure_macq UNIQUE(macq_acq_id, macq_var_id, macq_date_measure),
 CONSTRAINT t_measure_macq_pkey PRIMARY KEY(macq_id),
 CONSTRAINT c_fk_acq_macq FOREIGN KEY (macq_acq_id)
   REFERENCES public.t_acquisition_acq(acq_id)
   ON DELETE NO ACTION
   ON
UPDATE NO ACTION
   NOT DEFERRABLE
,
 CONSTRAINT c_fk_fil_macq FOREIGN KEY (macq_fil_id)
   REFERENCES public.tr_file_fil(fil_id)
   ON DELETE NO ACTION
   ON
UPDATE NO ACTION
   NOT DEFERRABLE
,
 CONSTRAINT c_fk_prot_macq FOREIGN KEY (macq_prot_id)
   REFERENCES public.tr_protocol_prot(prot_id)
   ON DELETE NO ACTION
   ON
UPDATE NO ACTION
   NOT DEFERRABLE
,
 CONSTRAINT c_fk_std_macq FOREIGN KEY (macq_std_id)
   REFERENCES public.tr_standard_std(std_id)
   ON DELETE NO ACTION
   ON
UPDATE NO ACTION
   NOT DEFERRABLE
,
 CONSTRAINT c_fk_tym_macq FOREIGN KEY (macq_tym_id)
   REFERENCES public.tr_type_measure_tym(tym_id)
   ON DELETE NO ACTION
   ON
UPDATE NO ACTION
   NOT DEFERRABLE
,
 CONSTRAINT c_fk_uni_macq FOREIGN KEY (macq_uni_id)
   REFERENCES public.tr_unit_uni(uni_id)
   ON DELETE NO ACTION
   ON
UPDATE NO ACTION
   NOT DEFERRABLE
,
 CONSTRAINT c_fk_var_macq FOREIGN KEY (macq_var_id)
   REFERENCES public.tr_variable_var(var_id)
   ON DELETE NO ACTION
   ON
UPDATE NO ACTION
   NOT DEFERRABLE

) ;

COMMENT ON TABLE public.t_measure_macq
IS 'Table of measurements of acquisitions';

COMMENT ON COLUMN public.t_measure_macq.macq_id
IS 'Digital automatic identifier of the acquisition measurement';

COMMENT ON COLUMN public.t_measure_macq.macq_acq_id
IS 'Identifier of the corresponding singularity detection';

COMMENT ON COLUMN public.t_measure_macq.macq_var_id
IS 'Identifier of the corresponding variable measured';

COMMENT ON COLUMN public.t_measure_macq.macq_uni_id
IS 'Identifier of the corresponding unit of the variable measured';

COMMENT ON COLUMN public.t_measure_macq.macq_fil_id
IS 'Identifier of the file in which the measurement has been provided';

COMMENT ON COLUMN public.t_measure_macq.macq_std_id
IS 'Identifier of the associated standard to the measurement';

COMMENT ON COLUMN public.t_measure_macq.macq_tym_id
IS 'Identifier of the type of measurement';

COMMENT ON COLUMN public.t_measure_macq.macq_prot_id
IS 'Identifier of the protocol applied for the measurement';

COMMENT ON COLUMN public.t_measure_macq.macq_value_num
IS 'value of the measurement if numeric type';

COMMENT ON COLUMN public.t_measure_macq.macq_value_text
IS 'value of the measurement if text type';

COMMENT ON COLUMN public.t_measure_macq.macq_value_date
IS 'value of the measure if it is a date type';

COMMENT ON COLUMN public.t_measure_macq.macq_date_measure
IS 'date of the measure';

COMMENT ON COLUMN public.t_measure_macq.macq_precision_date_measure
IS 'Accuracy of the date of the measurement';

COMMENT ON COLUMN public.t_measure_macq.macq_precision_measure
IS 'Acuracy of the measurement';

COMMENT ON COLUMN public.t_measure_macq.macq_observation
IS 'Additional information about the measurement';

COMMENT ON CONSTRAINT c_fk_acq_macq ON public.t_measure_macq
IS 'a measure must be attached to one and only one acquisition';

COMMENT ON CONSTRAINT c_fk_fil_macq ON public.t_measure_macq
IS 'a measure can be attached to O or 1 file';

COMMENT ON CONSTRAINT c_fk_prot_macq ON public.t_measure_macq
IS 'a measure can be attached to O or 1 protocol';

COMMENT ON CONSTRAINT c_fk_std_macq ON public.t_measure_macq
IS 'a measure can be attached to O or 1 unit';

COMMENT ON CONSTRAINT c_fk_tym_macq ON public.t_measure_macq
IS 'a measure can be attached to O or 1 type of measure';

COMMENT ON CONSTRAINT c_fk_uni_macq ON public.t_measure_macq
IS 'a measure can be attached to O or 1 unit';

COMMENT ON CONSTRAINT c_fk_var_macq ON public.t_measure_macq
IS 'a measure must be attached to one and only one variable';

COMMENT ON CONSTRAINT c_uni_acq_var_datemeasure_macq ON public.t_measure_macq
IS 'The set identifier of the acquisition / identifier of the variable / date of the measure is unique';

CREATE UNIQUE INDEX c_uni_acq_var_macq ON public.t_measure_macq
 USING btree (macq_acq_id, macq_var_id)
 WHERE (macq_date_measure IS NULL);

COMMENT ON INDEX public.c_uni_acq_var_macq
IS 'The variable / acquisition pair is unique if the measure date is not entered.';

CREATE INDEX x_btr_fkey_acq_macq ON public.t_measure_macq
 USING btree (macq_acq_id);

COMMENT ON INDEX public.x_btr_fkey_acq_macq
IS 'Foreign key index to speed up updates / deletion';

CREATE INDEX x_btr_fkey_fil_macq ON public.t_measure_macq
 USING btree (macq_fil_id);

COMMENT ON INDEX public.x_btr_fkey_fil_macq
IS 'Foreign key index to speed up updates / deletion';

CREATE INDEX x_btr_fkey_prot_macq ON public.t_measure_macq
 USING btree (macq_prot_id);

COMMENT ON INDEX public.x_btr_fkey_prot_macq
IS 'Foreign key index to speed up updates / deletion';

CREATE INDEX x_btr_fkey_std_macq ON public.t_measure_macq
 USING btree (macq_std_id);

COMMENT ON INDEX public.x_btr_fkey_std_macq
IS 'Foreign key index to speed up updates / deletion';

CREATE INDEX x_btr_fkey_tym_macq ON public.t_measure_macq
 USING btree (macq_tym_id);

COMMENT ON INDEX public.x_btr_fkey_tym_macq
IS 'Foreign key index to speed up updates / deletion';

CREATE INDEX x_btr_fkey_uni_macq ON public.t_measure_macq
 USING btree (macq_uni_id);

COMMENT ON INDEX public.x_btr_fkey_uni_macq
IS 'Foreign key index to speed up updates / deletion';

CREATE INDEX x_btr_fkey_var_macq ON public.t_measure_macq
 USING btree (macq_var_id);

COMMENT ON INDEX public.x_btr_fkey_var_macq
IS 'Foreign key index to speed up updates / deletion';

This file was generated with SQL Manager for PostgreSQL (www.pgsqlmanager.com) at 07/12/2018 13:23
Previous topic Chapter index Next topic