Error: ext: Data form could not be loaded when trying to commit a batch.

The following error appears as a validation error when trying to commit a batch. 

Error: ext: Data form could not be loaded.  FOR XML could not serialize the data for node 'CITY' because it contains a character (0x0005) which is not allowed in XML. To retrieve this data using FOR XML, convert it to binary, varbinary or image data type and use the BINARY BASE64 directive.BBERR_ORIGINAL_ERROR:6841BBERR_ORIGINAL_PROCEDURE:USP_EDITLOAD_BATCHCONSTITUENTUPDATEBATCHROWBBERR_ORIGINAL_LINE_NUMBER:140

This was a data issue caused by a conversion.  Problem records were identified with the below script and the city was deleted/re-added in the front end:

select A.City as [ADDRESS],C.LOOKUPID as [CONSTITUENT],
  patindex('%[^ !-~]%' COLLATE Latin1_General_BIN,CITY) as [Position],
  substring(CITY,patindex('%[^ !-~]%' COLLATE Latin1_General_BIN,CITY),1) as [InvalidCharacter],
  ascii(substring(CITY,patindex('%[^ !-~]%' COLLATE Latin1_General_BIN,CITY),1)) as [ASCIICode]
from  ADDRESS A
join CONSTITUENT C on
A.CONSTITUENTID=C.ID
where patindex('%[^ !-~]%' COLLATE Latin1_General_BIN,CITY) >0
and ascii(substring(CITY,patindex('%[^ !-~]%' COLLATE Latin1_General_BIN,CITY),1)) in ('5')

Environment

 3.0.516.28

Was this article helpful?