When an import rule imports records that have blank fields encapsulated by double quotation marks, such as "" or '', the data class is not blanked but contains the quotation marks instead.
This is working as designed. Data Connector has no pre-processing ability to remove extra values, such as quotation marks, from the value of a CSV file, and does not see this as "remove the current value" therefore.
Three workarounds exists for this:
- Use correct CSV formatting for the data source file. Remove all quotation marks that are encapsulating field values. This will then result in an error and skip the row, however, as no value is present to import (refer to TECH202549, below, for more information about why this happens).
- Or, add pre-processing to the data source to find and replace the double quotation marks with a null value. The following code demonstrates how this can be done, by using the Initials field for a User resource type when using double "" (this can be changed to '' as necessary):
for (int i = 0; i < importData.Rows.Count; i++)
DataRow row = importData.Rows[i];
if ((string)row["Initials"] == "\"")
row["Initials"] = System.DBNull.Value;
Data Connector import rule fails to remove a specific column's existing value when it is set to be blank
How to troubleshoot import issues when using a Data Connector import rule
Imported Document Id