dbfile.check.Rd
Function to check to see if a file exists in the dbfiles table
dbfile.check(type, container.id, con, hostname = PEcAn.remote::fqdn(), machine.check = TRUE, return.all = FALSE)
type | the type of dbfile (Input, Posterior) |
---|---|
container.id | the id of container type |
con | database connection object |
hostname | the name of the host where the file is stored, this will default to the name of the current machine |
machine.check | setting to check for file on named host, otherwise will check for any file given container id |
return.all | logical flag, if TRUE will return all the files in the directory, not only the max(dbfiles$updated_at) subset |
data.frame with the id, filename and pathname of all the files that are associated
This will check the dbfiles and machines to see if the file exists
# NOT RUN { dbfile.check('Input', 7, dbcon) # }