Generic database insert function.
Adds the given heartbeat to database. The beat data is validated by default.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(db_type), | intent(inout) | :: | db |
Database type. |
||
type(beat_type), | intent(inout) | :: | beat |
Beat to insert. |
||
type(db_stmt_type), | intent(inout), | optional | :: | db_stmt |
Database statement type. |
|
logical, | intent(in), | optional | :: | validate |
Validate beat. |
Adds array of beats to database. A transaction is used unless
transaction
is .false.
. The beat data is validated by default.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(db_type), | intent(inout) | :: | db |
Database type. |
||
type(beat_type), | intent(inout) | :: | beats(:) |
Beat type array. |
||
logical, | intent(in), | optional | :: | transaction |
Use SQL transaction. |
|
logical, | intent(in), | optional | :: | validate |
Validate beats. |
Adds the given log to database. The log data is validated by default.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(db_type), | intent(inout) | :: | db |
Database type. |
||
type(log_type), | intent(inout) | :: | log |
Log message to insert. |
||
logical, | intent(in), | optional | :: | validate |
Validate log. |
Adds the given node to database. The node data is validated by default.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(db_type), | intent(inout) | :: | db |
Database type. |
||
type(node_type), | intent(inout) | :: | node |
Node to insert. |
||
logical, | intent(in), | optional | :: | validate |
Validate node. |
Adds single observation to database, including receivers, requests, and responses. If the insert query fails, the transaction will be rolled back, i.e., no part of the observation is written to the database on error. The observation data is validated by default.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(db_type), | intent(inout) | :: | db |
Database type. |
||
type(observ_type), | intent(inout) | :: | observ |
Observation type. |
||
type(db_stmt_type), | intent(inout), | optional | :: | db_stmt |
Database statement type. |
|
logical, | intent(in), | optional | :: | validate |
Validate observation. |
Adds array of observations to database. A transaction is used unless
transaction
is .false.
. The observation data is validated by
default.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(db_type), | intent(inout) | :: | db |
Database type. |
||
type(observ_type), | intent(inout) | :: | observs(:) |
Observation type array. |
||
logical, | intent(in), | optional | :: | transaction |
Use SQL transaction. |
|
logical, | intent(in), | optional | :: | validate |
Validate observations. |
Adds given sensor to database. The sensor data is validated by default.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(db_type), | intent(inout) | :: | db |
Database type. |
||
type(sensor_type), | intent(inout) | :: | sensor |
Sensor to insert. |
||
logical, | intent(in), | optional | :: | validate |
Validate sensor. |
Adds given target to database. The target data is validated by default.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(db_type), | intent(inout) | :: | db |
Database type. |
||
type(target_type), | intent(inout) | :: | target |
Target to insert. |
||
logical, | intent(in), | optional | :: | validate |
Validate target. |