R/peekds_validators.R
ds.validate_for_db_import.Rdcheck all csv files against database schema for database import
ds.validate_for_db_import(
dir_csv,
cdi_expected,
file_ext = ".csv",
is_null_field_required = TRUE
)the folder directory containing all the csv files, the path should end in "processed_data"
specifies whether cdi_data is to be expected to be present in the imported data
the default is ".csv"
by default is set to TRUE which means that all the columns in the json file are required; when set to FALSE, fields that are allowed null values are not required
an empty string if all tables passed the validator; otherwise, the function returns a list of messages describing detailed issues that needs to be fixed
if (FALSE) { # \dontrun{
msg_error_all <-ds.validate_for_db_import(dir_csv = "./processed_data")
} # }