Guest_imported
New member
- Jan 1, 1970
- 0
I would normal keep reading to creat this myself but I am pressed for time. Scenario : an object with a ToXML method that is not returning and easy to work with XML doc. I am trying to create a XSL template to transform this into another XML structure to import into SQL2K.
If anybody would give me a swift kick to get me going I would appreciate it. I already have one in place but I am having trouble to design the XLS template to return the fields in an element vs attribute.
here is a portion:
<?xml version="1.0" standalone="yes"?><appconn><recordset><metadata><fieldmetadata iskey="false" isreadable="true" iswriteable="false" length="14" name="REFER" terminalattributesenabled="false" type="field"><description/></fieldmetadata><fieldmetadata iskey="false" isreadable="true" iswriteable="false" length="23" name="PART" terminalattributesenabled="false" type="field"><description/></fieldmetadata><fieldmetadata iskey="false" isreadable="true" iswriteable="false" length="7" name="OH" terminalattributesenabled="false" type="field"><description/></fieldmetadata><fieldmetadata iskey="false" isreadable="true" iswriteable="false" length="5" name="QO" terminalattributesenabled="false" type="field"><description/></fieldmetadata><fieldmetadata iskey="false" isreadable="true" iswriteable="false" length="5" name="QS" terminalattributesenabled="false" type="field"><description/></fieldmetadata><fieldmetadata iskey="false" isreadable="true" iswriteable="false" length="26" name="CUST" terminalattributesenabled="false" type="field"><description/></fieldmetadata></metadata><records><modelrecord index="1"><field name="REFER">168455X3</field><field name="PART">SHA*400-1*</field><field name="OH">0</field><field name="QO">1</field><field name="QS">0</field><field name="CUST">80693</field></modelrecord><modelrecord index="2"><field name="REFER">168455X3</field><field name="PART">TRIP*4106*</field><field name="OH">0</field><field name="QO">1</field><field name="QS">0</field><field name="CUST">80693</field></modelrecord></records></recordset></appconn>
Basically looking to create another XML structure with
<recordset>
<record index="1">
<REFER></REFER>
<PART></PART>
<OH></OH>
<QO></QO>
<QS></QS>
<CUST></CUST>
</record>
</recordset>
I would highly appreciate any help!!
If anybody would give me a swift kick to get me going I would appreciate it. I already have one in place but I am having trouble to design the XLS template to return the fields in an element vs attribute.
here is a portion:
<?xml version="1.0" standalone="yes"?><appconn><recordset><metadata><fieldmetadata iskey="false" isreadable="true" iswriteable="false" length="14" name="REFER" terminalattributesenabled="false" type="field"><description/></fieldmetadata><fieldmetadata iskey="false" isreadable="true" iswriteable="false" length="23" name="PART" terminalattributesenabled="false" type="field"><description/></fieldmetadata><fieldmetadata iskey="false" isreadable="true" iswriteable="false" length="7" name="OH" terminalattributesenabled="false" type="field"><description/></fieldmetadata><fieldmetadata iskey="false" isreadable="true" iswriteable="false" length="5" name="QO" terminalattributesenabled="false" type="field"><description/></fieldmetadata><fieldmetadata iskey="false" isreadable="true" iswriteable="false" length="5" name="QS" terminalattributesenabled="false" type="field"><description/></fieldmetadata><fieldmetadata iskey="false" isreadable="true" iswriteable="false" length="26" name="CUST" terminalattributesenabled="false" type="field"><description/></fieldmetadata></metadata><records><modelrecord index="1"><field name="REFER">168455X3</field><field name="PART">SHA*400-1*</field><field name="OH">0</field><field name="QO">1</field><field name="QS">0</field><field name="CUST">80693</field></modelrecord><modelrecord index="2"><field name="REFER">168455X3</field><field name="PART">TRIP*4106*</field><field name="OH">0</field><field name="QO">1</field><field name="QS">0</field><field name="CUST">80693</field></modelrecord></records></recordset></appconn>
Basically looking to create another XML structure with
<recordset>
<record index="1">
<REFER></REFER>
<PART></PART>
<OH></OH>
<QO></QO>
<QS></QS>
<CUST></CUST>
</record>
</recordset>
I would highly appreciate any help!!