check 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
)

Arguments

dir_csv

the folder directory containing all the csv files, the path should end in "processed_data"

cdi_expected

specifies whether cdi_data is to be expected to be present in the imported data

file_ext

the default is ".csv"

Value

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

Examples

if (FALSE) { # \dontrun{
msg_error_all <-ds.validate_for_db_import(dir_csv = "./processed_data")
} # }