Hi,
I am creating a xml file thru datastage.
For one column I have appended a '<' symbol before the column value
When I am opening the file thru internet explorer, I can able to see < symbol before the column value.
But When I am opening the xml file in notepad, it is replacing the character as <
My requirement is when i open the file in notepad < symbol should appear before the column value
Can any one help me to find out the solution for this?
Datastage is replacing < symbol as < in XML file
Moderators: chulett, rschirm, roy
They are equivalent and really shouldn't case a problem.
When you generate the XML Output, do you have the 'Data Element' column set to 'XML'? My understanding is that data element type is responsible for making those 'safe XML' substitutions. So, if it says XML make it blank... or perhaps vice-versa. Pretty sure that will solve your problem. Let us know!![Wink :wink:](./images/smilies/icon_wink.gif)
When you generate the XML Output, do you have the 'Data Element' column set to 'XML'? My understanding is that data element type is responsible for making those 'safe XML' substitutions. So, if it says XML make it blank... or perhaps vice-versa. Pretty sure that will solve your problem. Let us know!
![Wink :wink:](./images/smilies/icon_wink.gif)
-craig
"You can never have too many knives" -- Logan Nine Fingers
"You can never have too many knives" -- Logan Nine Fingers
Hi
Hi,
Ihave not selected the DataElements.
Let me try byselecting the DataElements as XML. I ll reply to you on Monday.
Ihave not selected the DataElements.
Let me try byselecting the DataElements as XML. I ll reply to you on Monday.
chulett wrote:They are equivalent and really shouldn't case a problem.
When you generate the XML Output, do you have the 'Data Element' column set to 'XML'? My understanding is that data element type is responsible for making those 'safe XML' substitutions. So, if it says XML make it blank... or perhaps vice-versa. Pretty sure that will solve your problem. Let us know!
Dilip Das
I don't think this is a case of creating 'safe XML' substitutions. There are a number of reserved characters in XML and one of these is '<'. You cannot have one of these appearing in the data because any XML reader will interpret this as the start of a new tag. Hence they must be replaced with those special strings (<) in order to create form well-formed documents.
The fact that an XML reader such as Internet Explorer interprets the character correctly shows that it is correct. If you replaced this with an actual '<' character, you would find that XML readers would throw an error.
You need to sort out the requirements. Do you want a well-formed XML document or do you want a text document that looks a little bit like XML.
The fact that an XML reader such as Internet Explorer interprets the character correctly shows that it is correct. If you replaced this with an actual '<' character, you would find that XML readers would throw an error.
You need to sort out the requirements. Do you want a well-formed XML document or do you want a text document that looks a little bit like XML.
Jim Paradies
Hi,
I have selected XML as Dataelement and it is working file.
Thanks
I have selected XML as Dataelement and it is working file.
Thanks
jzparad wrote:I don't think this is a case of creating 'safe XML' substitutions. There are a number of reserved characters in XML and one of these is '<'. You cannot have one of these appearing in the data because any XML reader will interpret this as the start of a new tag. Hence they must be replaced with those special strings (<) in order to create form well-formed documents.
The fact that an XML reader such as Internet Explorer interprets the character correctly shows that it is correct. If you replaced this with an actual '<' character, you would find that XML readers would throw an error.
You need to sort out the requirements. Do you want a well-formed XML document or do you want a text document that looks a little bit like XML.
Dilip Das
You're right in saying that this will achieve what you want. Basically, you're telling DataStage that this field contains a valid XML chunk so don't bother converting it.I have selected XML as Dataelement and it is working file.
My point however is that you no longer have a valid XML document. If you try to open that file in Internet Explorer, you will receive an error.
In any case, if this is truly your requirement, then it's OK!
Jim Paradies
I can able to open the xml file in Internet Explorer without any error.
jzparad wrote:You're right in saying that this will achieve what you want. Basically, you're telling DataStage that this field contains a valid XML chunk so don't bother converting it.I have selected XML as Dataelement and it is working file.
My point however is that you no longer have a valid XML document. If you try to open that file in Internet Explorer, you will receive an error.
In any case, if this is truly your requirement, then it's OK!
Dilip Das