$result = self::_CsvToTable(
$file,
$firstRowIsColumnHeader,
- NULL,
CRM_Utils_Array::value('fieldSeparator', $params, ',')
);
* File name to load.
* @param bool $headers
* Whether the first row contains headers.
- * @param string $tableName
- * Name of table from which data imported.
* @param string $fieldSeparator
* Character that separates the various columns in the file.
*
private static function _CsvToTable(
$file,
$headers = FALSE,
- $tableName = NULL,
$fieldSeparator = ','
) {
$result = [];
}
}
- if ($tableName) {
- CRM_Core_DAO::executeQuery("DROP TABLE IF EXISTS $tableName");
- }
$table = CRM_Utils_SQL_TempTable::build()->setDurable();
$tableName = $table->getName();
CRM_Core_DAO::executeQuery("DROP TABLE IF EXISTS $tableName");