Skip to main content
Announcements
See what Drew Clarke has to say about the Qlik Talend Cloud launch! READ THE BLOG
cancel
Showing results for 
Search instead for 
Did you mean: 
_AnonymousUser
Creator III
Creator III

Distinguishing null values, empty values and elements not present

Hello,
we are building an webservice that will be updating data. For simplicity, lets assume that there are 3 elements that can be updated (A as xs:string, B as xs:date and C as xs:integer).
We need to be able to distinguish whether element was ommited in the request (means - do not update), was present and was set to null value (empty string or xsi:nil, means - update and set to null), was present and was set to not null value (means - update to given value).
What is the best approach to accomplish this in Talend ESB? It seems like ommited elements and elements with empty/null value are both treated as "null" in tXMLMap.
Any advice appreciated.
Few examples:
<A>val1</A><B>2015-01-01Z</B><C>1</C> <!-- update all -->
<A>val1</A><C>1</C> <!-- update A and C, leave B unchanged -->
<A>val1</A><C xsi:nil="true" /> <!-- update A, leave B unchanged, set C to null -->
Labels (3)
10 Replies
Anonymous
Not applicable

Well spotted. There is a Jira site for raising issues like this. I think your description there would be good enough to point the developers in the right direction. The link to the Jira site is https://jira.talendforge.org/secure/Dashboard.jspa