Author |
Message
|
pauillac |
Posted: Thu Mar 14, 2002 1:46 am Post subject: |
|
|
Novice
Joined: 13 Jul 2001 Posts: 21
|
Hi,
Q1. Is it possible to generate the empty tag in the format <tagname/> in MQSI 2.1?
Q2. Is there any way of differentiate <tagname></tagname> and <tagname/> in MQSI 2.1?
Thanks,
C.K. |
|
Back to top |
|
 |
chanduy9 |
Posted: Thu Mar 14, 2002 2:35 pm Post subject: |
|
|
Disciple
Joined: 28 Nov 2001 Posts: 177 Location: USA
|
Hi,
just pass null value to that tag it will genarate the <tagname/>, i hope there is no difference between those.
try this,
SET OutputRoot.XML.Body.Tagname='';
good luck,
Chandra. |
|
Back to top |
|
 |
pauillac |
Posted: Thu Mar 14, 2002 4:24 pm Post subject: |
|
|
Novice
Joined: 13 Jul 2001 Posts: 21
|
Hi Chandra,
I already tried this to no avail in MQSI 2.1. In MQSI 2.0.2, it is possible to generate <tagname/> but in this version it cannot.
The reason why I want to do this is the consultancy firm AccXnture suggests using <tagname></tagname> for "EMPTY" and <tagname/> for "NULL" in Siebel. "EMPTY" means no value for the tag and "NULL" means this tag should be ignored entirely. I think this is an abuse of XML but AccXnture is really domineering. Any other suggestions?
Thanks
|
|
Back to top |
|
 |
amigupta1978 |
Posted: Thu Mar 14, 2002 5:36 pm Post subject: |
|
|
Centurion
Joined: 22 Jan 2002 Posts: 132 Location: India
|
Hi
Use like this
SET OutputRoot.XML.tag1.tag2.(XML.Content) = NULL;
generates the following XML:
<tag1><tag2/></tag1>
Regards
Amit
|
|
Back to top |
|
 |
pauillac |
Posted: Fri Mar 15, 2002 3:10 am Post subject: |
|
|
Novice
Joined: 13 Jul 2001 Posts: 21
|
Hi,
Thanks a lot. One more question.
Input XML's:
1. <test><tagname></tagname></test>
2. <test><tagname/></test>
Is it possible to differentiate the input XML's for different processing in ESQL?
Thanks |
|
Back to top |
|
 |
jfluitsm |
Posted: Fri Mar 15, 2002 7:47 am Post subject: |
|
|
Disciple
Joined: 24 Feb 2002 Posts: 160 Location: The Netherlands
|
Hi,
I guess tagname = '' or tagname.(XML.Content) = '' for the first and tagname.(XML.Content) = NULL for the second. Just try.
_________________ Jan Fluitsma
IBM Certified Solution Designer WebSphere MQ V6
IBM Certified Solution Developer WebSphere Message Broker V6 |
|
Back to top |
|
 |
jfluitsm |
Posted: Fri Mar 15, 2002 8:22 am Post subject: |
|
|
Disciple
Joined: 24 Feb 2002 Posts: 160 Location: The Netherlands
|
I tried it, doesn't work.
Setting XML.Content to NULL is only a 'trick' to force the short form of an empty tag.
It looks like it's not possible to distinquise the difference in an input message, which is all to well as according to the XML standard there is no difference.
_________________ Jan Fluitsma
IBM Certified Solution Designer WebSphere MQ V6
IBM Certified Solution Developer WebSphere Message Broker V6 |
|
Back to top |
|
 |
|