Author |
Message
|
biswagourab |
Posted: Tue May 15, 2007 9:39 pm Post subject: Multiple Headers in XML |
|
|
 Apprentice
Joined: 31 May 2005 Posts: 47 Location: London
|
Hi,
I am looking to create an XML output header which looks like this.
<?xml version="1.0" encoding="UTF-8" ?>
<?Siebel-Property-Set EscapeNames="true"?>
I tried this code
SET OutputRoot.XML.(XML.XmlDecl).(XML.Version) = '1.0';
SET OutputRoot.XML.(XML.XmlDecl).(XML."Encoding") = 'UTF-8';
SET OutputRoot.XML.(XML.XmlDecl).(XML.Siebel-Property-Set)='';
SET OutputRoot.XML.(XML.XmlDecl).(XML."EscapeNames")='true';
The first line is getting created. But the second header is not getting created.
Can anyone please guide.
Thanks |
|
Back to top |
|
 |
jefflowrey |
Posted: Wed May 16, 2007 4:20 am Post subject: |
|
|
Grand Poobah
Joined: 16 Oct 2002 Posts: 19981
|
Do not use the XML domain. _________________ I am *not* the model of the modern major general. |
|
Back to top |
|
 |
vk |
Posted: Wed May 16, 2007 4:25 am Post subject: |
|
|
Partisan
Joined: 20 Sep 2005 Posts: 302 Location: Houston
|
Quote: |
Do not use the XML domain. |
Jeff,
Are you telling not to use XML domain in this case or not to use XML domain at all in any case and use XMLNS instead? Can I know the reason? I have a lot of interfaces in XML domain.
Regards,
VK. |
|
Back to top |
|
 |
jefflowrey |
Posted: Wed May 16, 2007 4:27 am Post subject: |
|
|
Grand Poobah
Joined: 16 Oct 2002 Posts: 19981
|
XML domain has been deprecated since v5. There's a post about it from shanson somewhere, that details whys and wherefores.
Also, if you're still on 2.1, then you likely won't be able to build this message the way you want to. _________________ I am *not* the model of the modern major general. |
|
Back to top |
|
 |
marcin.kasinski |
Posted: Wed May 16, 2007 4:29 am Post subject: |
|
|
Sentinel
Joined: 21 Dec 2004 Posts: 850 Location: Poland / Warsaw
|
vk wrote: |
Quote: |
Do not use the XML domain. |
Jeff,
Are you telling not to use XML domain in this case or not to use XML domain at all in any case and use XMLNS instead? Can I know the reason? I have a lot of interfaces in XML domain.
Regards,
VK. |
To parse XML you can use other better domains XMLNS or XMLNSC.
XML domain is deprecated. _________________ Marcin |
|
Back to top |
|
 |
elvis_gn |
Posted: Wed May 16, 2007 4:54 am Post subject: |
|
|
 Padawan
Joined: 08 Oct 2004 Posts: 1905 Location: Dubai
|
Hi biswagourab,
Code: |
SET OutputRoot.XMLNS.(XML.XmlDecl)"Siebel-Property-Set" ='';
SET OutputRoot.XMLNS.(XML.XmlDecl)"Siebel-Property-Set".(XML.attr)"EscapeNames" = 'true';
|
You should find that this gets created atleast in the compute, but it will throw an error at the ouput node saying
Quote: |
Duplicate XML or DOCTYPE declaration of element ''Siebel-Property-Set''. |
Perhaps a BLOB conversion might be required for that...
Regards. |
|
Back to top |
|
 |
biswagourab |
Posted: Wed May 16, 2007 4:55 am Post subject: |
|
|
 Apprentice
Joined: 31 May 2005 Posts: 47 Location: London
|
I am currently on WBIMB 6.0, So should I be able to build this structure ?
The output that is required is in the XML domain.... So is there any way I can create it as it is asked ?
Thanks for the help ... |
|
Back to top |
|
 |
kimbert |
Posted: Thu May 17, 2007 2:54 am Post subject: |
|
|
 Jedi Council
Joined: 29 Jul 2003 Posts: 5542 Location: Southampton
|
The second line is not an XMLDecl - it's a processing instruction. |
|
Back to top |
|
 |
dcapodic |
Posted: Thu May 17, 2007 9:17 am Post subject: |
|
|
Apprentice
Joined: 03 Sep 2003 Posts: 32
|
jefflowrey wrote: |
XML domain has been deprecated since v5. There's a post about it from shanson somewhere, that details whys and wherefores.
Also, if you're still on 2.1, then you likely won't be able to build this message the way you want to. |
Interesting The XML domain is depricated yet in version 6 examples and version 6 docs, they all use the XML domain with no mention of it being depricated? Is this an "offical" IBM stance?
By the way, not asking as an "accusation" but as a true question If this is true, then I would have a REAL issue with IBM about this. As mentioned by another, we have virtually all of our code built with the XML domain. I know we can change it and probably not run into any isses but why would we since we did not know that the XML domain was deprecated. I would then ask IBM why they would not mention it very openly (if at all) in their verion 6 docs and why they would give examples in version 6 using the XML domain. If anyone has any insight, I would be grateful to hear it  |
|
Back to top |
|
 |
kimbert |
Posted: Thu May 17, 2007 12:03 pm Post subject: |
|
|
 Jedi Council
Joined: 29 Jul 2003 Posts: 5542 Location: Southampton
|
You won't hear me calling the XML domain 'deprecated'. IBM has no plans to withdraw the XML domain in a future release. But it has no plans to enhance the XML domain either. So if you want to be positioned to take advantage of any future XML parser enhancements, use something else. |
|
Back to top |
|
 |
jefflowrey |
Posted: Thu May 17, 2007 12:14 pm Post subject: |
|
|
Grand Poobah
Joined: 16 Oct 2002 Posts: 19981
|
|
Back to top |
|
 |
dcapodic |
Posted: Thu May 17, 2007 7:41 pm Post subject: |
|
|
Apprentice
Joined: 03 Sep 2003 Posts: 32
|
Thanks for posting the "obscure" reference that I hinted at earleir It would seem much more logical to have it a bit more plain to see that use of the XML domain is no longer recommended but that's just me! |
|
Back to top |
|
 |
dcapodic |
Posted: Thu May 17, 2007 7:50 pm Post subject: |
|
|
Apprentice
Joined: 03 Sep 2003 Posts: 32
|
kimbert wrote: |
You won't hear me calling the XML domain 'deprecated'. IBM has no plans to withdraw the XML domain in a future release. But it has no plans to enhance the XML domain either. So if you want to be positioned to take advantage of any future XML parser enhancements, use something else. |
Very political answer My thanks to all of the Hursley personnel who frequent this and other boards to get the real info out on the "what to do and how to do them" about their software. Yours is not the word we normally get to hear so it is always a pleasure to get the real technical leadership that we all desire.
Let's see....it was the standard and has now been replaced by not one but two newer, enhanced versions....is listed as being provided for "only for compatibility with WebSphere MQ Integrator Version 2"....and its use is recommended against....but it is not deprecated
From Wikipedia...."In computer software standards and documentation, the term deprecation is used to discourage usage of a particular software feature, usually because it has been superseded by a newer/better version. The deprecated feature still works in the current version of the software".... |
|
Back to top |
|
 |
biswagourab |
Posted: Fri May 18, 2007 2:23 am Post subject: |
|
|
 Apprentice
Joined: 31 May 2005 Posts: 47 Location: London
|
Thanks for all that information.  |
|
Back to top |
|
 |
manojsu |
Posted: Sun May 20, 2007 10:53 pm Post subject: |
|
|
Centurion
Joined: 19 Jul 2006 Posts: 147 Location: Bangalore
|
Hi,
Please acknowledge whether your problem is fixed or its still recurring or you finally managed to get a solution with a work around.
Regards
S.Manoj |
|
Back to top |
|
 |
|