copyFrom = async (fileStream, tableName, fieldNames, client) => {
  const sql = `COPY "${getTenantSchema()}"."${sqlsanitize(
    tableName
  )}" (${fieldNames.map(quote).join(",")}) FROM STDIN CSV HEADER`;
  sql_log(sql);

  const stream = client.query(copyStreams.from(sql));
  return await pipeline(fileStream, stream);
}
Copy data from CSV to table?
Only for PG
@param {object} fileStream - file stream
@param {string} tableName - table name
@param {string[]} fieldNames - list of columns
@param {object} client - db connection
@returns {Promise<void>} no results