Skip to content

Latest commit

 

History

History
50 lines (35 loc) · 4.71 KB

parameters.rst

File metadata and controls

50 lines (35 loc) · 4.71 KB

Parameters

The E-Maj extension works with some parameters. Those are stored into the emaj_param internal table.

The emaj_param table structure is the following:

Column Type Description
param_key TEXT keyword identifying the parameter
param_value_text TEXT parameter value, if its type is text (otherwise NULL)
param_value_int INT parameter value, if its type is integer (otherwise NULL)
param_value_boolean BOOLEAN parameter value, if its type is boolean (otherwise NULL)
param_value_interval INTERVAL parameter value, if its type is time interval (otherwise NULL)

The E-Maj extension installation procedure inserts a single row into the emaj_param table. This row, that should not be modified, describes parameter:

  • version : (text) current E-Maj version.

But the E-Maj administrator may insert other rows into the emaj_param table to change the default value of some parameters.

Presented in alphabetic order, the existing key values are:

Below is an example of a SQL statement that defines a retention delay of history table's rows equal to 3 months:

INSERT INTO emaj.emaj_param (param_key, param_value_interval) VALUES ('history_retention','3 months'::interval);

It is also possible to manage parameter values using any graphic tool such as PgAdmin or phpPgAdmin.

Only superuser and roles having emaj_adm rights can access the emaj_param table.

Roles having emaj_viewer rights can only access a part of the emaj_param table, through the emaj.emaj_visible_param view. This view just masks the real value of the param_value_text column for the 'dblink_user_password' key.