EDI: Handling null or empty values in XML format

Supported methods for passing Null or empty values:

The most explicit way to represent a null value in XML is to include an empty tag set for the data item.

The following entries would have the same result of wiping any existing item:





Unsupported methods for passing Null or empty values:

Another way to represent a null value would be to not iinclude the tags for that item. If a given record has no tags for a certain data item, it will be considered empty by eNICQ 6. One advantage of XML is that not all records have to even include the same set of field tags. Only the "minimum required fields" need to be present.

The disadvantage of this method is that it will not force an overwrite of the existing value if one already exists in the eNICQ 6 database.  Because this method will have different results in an update scenario versus an insert scenario, we advise sticking to the more consistent method of passing an empty tag set.

Another unsupported way to represent a null value in XML is by using the xsi:nil attribute.  W3C has this option, but we do not currently support it:

<HFNC36 xsi:nil="true"/>

Apparently 'xsi:nil' requires a library or include statement that our code is currently lacking. We may extend the application to support this option in the future, but for now please use one of the supported options.


What happens when you pass empty values:

Empty values passed in via an import will strip any value that currently exists for that data item for that record. What this means in the key/value pair design is that the field is wiped completely from the database for that item for that record. There is no "HFNC36" data item for that record any longer, so there actually is no value left whatsoever.

It is because of this design aspect that we consider eNICQ 6 to be "blind" to the notion of null values. It doesn't store them at all. The absence of a data item for a given record means that there is no value, not a null or empty value, but no value whatsoever. The data item no longer exists for the record, until such time it is filled again.  The eNICQ 6 application will assign a "blank" status to the data item and an "incomplete" status to the record (provided no other status applies.)

Have more questions? Submit a request


  • Avatar
    Ted Kreider

    This topic planned for inclusion in a later revision of the EDI Developer's guide.