dbAdd_integration: Add integration kind to 'integration' table

Description Usage Arguments Value See Also Examples

View source: R/db_write.R

Description

dbWriteTable_integration requires a correct device integration type id while dbAdd_integration derives that from the device model name.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
dbAdd_integration(
  conn,
  inttype_name,
  int_measurement_interval,
  int_interval,
  int_comment = NULL
)

dbWriteTable_integration(
  conn,
  inttype_id,
  int_measurement_interval,
  int_interval,
  int_comment = NULL
)

Arguments

conn

Database connection.

inttype_name

String vector of name of integration type.

int_measurement_interval

Numeric vector of intervals between measurements in s.

int_interval

Numeric vector of integration interval in s of one stored measurement.

int_comment

Character vector of additional information.

inttype_id

Integer vector of integration_type ID.

Value

Data frame of newly added rows.

See Also

Other custom dbWriteTable functions: dbAddCorrection_station_adlershof(), dbAddCorrection_station_patagonia(), dbAdd_calibration_state(), dbAdd_device_model(), dbAdd_device(), dbAdd_measurand(), dbAdd_physical_quantity(), dbAdd_station_adlershof(), dbAdd_station_patagonia(), dbWriteTable_device_manufacturer(), dbWriteTable_device_type(), dbWriteTable_integration_type(), dbWriteTable_person(), dbWriteTable_quality_flag(), dbWriteTable_site()

Examples

1
2
3
4
5
6
7
## Not run: 
con <- dbConnect_klimageo()
dbWriteTable_integration_type("average", "average value over a period")
dbWriteTable_integration(con, 1, 60, 600)
dbDisconnect(con)

## End(Not run)

sebschub/klimageodb documentation built on Sept. 25, 2021, 4:16 p.m.