| opal.table_save {opalr} | R Documentation | 
Save a local tibble as a Opal table
Description
Upload a local tibble to the R server side through Opal, assign this tibble to the provided symbol name and import it as a table into a Opal project.
Usage
opal.table_save(
  opal,
  tibble,
  project,
  table,
  overwrite = TRUE,
  force = FALSE,
  identifiers = NULL,
  policy = "required",
  id.name = "id",
  type = "Participant"
)
Arguments
| opal | Opal connection object. | 
| tibble | The tibble object to be imported. | 
| project | Project name where the table will be located. | 
| table | Destination table name. | 
| overwrite | If the destination table already exists, it will be replaced (deleted, re-created with associated permissions reinstated and then imported). Otherwise the table will be updated (data dictionaries merge may conflict). Default is TRUE. See also opal.table_truncate function. | 
| force | If the destination already exists, stop with an informative message if this flag is FALSE (default). | 
| identifiers | Name of the identifiers mapping to use when assigning entities to Opal. | 
| policy | Identifiers policy: 'required' (each identifiers must be mapped prior importation (default)), ignore' (ignore unknown identifiers) and 'generate' (generate a system identifier for each unknown identifier). | 
| id.name | The name of the column representing the entity identifiers. Default is 'id'. | 
| type | Entity type (what the data are about). Default is 'Participant' | 
Value
An invisible logical indicating whether the destination table exists.
See Also
Other table functions: 
opal.perms(),
opal.resource_view_create(),
opal.resource_view_reconnect(),
opal.table_create(),
opal.table_delete(),
opal.table_dictionary_get(),
opal.table_dictionary_update(),
opal.table_exists(),
opal.table_export(),
opal.table_get(),
opal.table_import(),
opal.table_perm_add(),
opal.table_perm_delete(),
opal.table_perm(),
opal.table_truncate(),
opal.table_view_create(),
opal.table_view_update()
Examples
## Not run: 
o <- opal.login('administrator','password', url='https://opal-demo.obiba.org')
cqx <- opal.table_get(o, "CPTP", "Cag_coreqx")
# do some (meta)data transformations, then save in opal's database
opal.table_save(o, cqx, "CPTP", "Cag_coreqx", overwrite = TRUE, force = TRUE)
# or overwrite data only (keep original data dictionary)
opal.table_save(o, cqx, "CPTP", "Cag_coreqx", overwrite = 'values', force = TRUE)
opal.logout(o)
## End(Not run)