dbfile.insert.Rd
Function to insert a file into the dbfiles table
dbfile.insert(in.path, in.prefix, type, id, con, reuse = TRUE, hostname = PEcAn.remote::fqdn())
in.path | Path to file directory |
---|---|
in.prefix | Filename prefix (not including directory) |
type | One of "Model", "Posterior", "Input" |
id | container_id of the input to be modified |
con | database connection object |
reuse | logical: If a record already exists, use it or create a new one? |
hostname | the name of the host where the file is stored, this will default to the name of the current machine |
id of the file that is written
This will write into the dbfiles and machines the required data to store the file
# NOT RUN { dbfile.insert('somefile.txt', 'Input', 7, dbcon) # }