EDN Admin
Well-known member
<pre class="prettyprint Hi All,
How do I copy part of xml from one xml to another. What I am doing here is to split 1 huge xml to another.
Say 600MB xmls into chunks of 6*100MB files. All 6 file need to have headers and standard set.
I have below XML , which I am trying to spli, however , I am unable to find a quick way to copy part of xml to another.
I do have a dll provided by internal tem
File 1.xml
<!-- ************** Block must go in all files -->
<ResultSetStatus State="Ready" PersistenceState="NotPersisted" TotalTradeCount="14" CompletedTradeCount="13" ErrorTradeCount="1" SensitivityErrorTradeCount="0" CalcServer="LDNDWM292011" LogFile="C:TEMPLogFilesExcelprocessor_9392.Flog3.log" BeginTimestamp="2012-09-18T15:17:15" EndTimestamp="2012-09-18T15:17:31
<Errors>
<Error>
<Severity>Warning</Severity>
<Source>EORE</Source>
<Id></Id>
<Message>EORE market data resolution warning: curve.swap/isk/reibo/* could not be mapped as the physical moniker was not resolvable.(object [official@20120824/curve.swap/emldnclose/isk/mid/reibor] not found in MX instance [me])</Message>
<ExtendedInfo></ExtendedInfo>
</Error>
<Error>
<Severity>Warning</Severity>
<Source>EORE</Source>
<Id></Id>
<Message>EORE market data resolution warning: curve.swap/nok could not be mapped as the physical moniker was not resolvable.(object [official@20120824/curve.swap/ldnficlose/nok/mid/nok6m ] not found in MX instance [me])</Message>
<ExtendedInfo></ExtendedInfo>
</Error>
<Errors>
<ResolvedTrades>
<Trade Moniker="ldn00c8f99a?version=45"/>
<Trade Moniker="ldn00c8ff71?version=53"/>
<Trade Moniker="ldn00c8ff72?version=48"/>
<Trade Moniker="ldn00c8fff0?version=49"/>
</ResolvedTrades>
<InputParameters>
<Trade Moniker="ldn00c8f99a?version=45"/>
<Trade Moniker="ldn00c8ff71?version=53"/>
<Trade Moniker="ldn00c8ff72?version=48"/>
<Trade Moniker="ldn00c8fff0?version=49"/>
</InputParameters>
<!-- ************** Block must go in all files -->
<!-- Below should split and copied into different files->
<languages>
<language>
<name>English</name>
<country>8</country>
<country>9</country>
<country>3</country>
<country>11</country>
<country>12</country>
</language>
<language>
<name>French</name>
<country>3</country>
<country>6</country>
<country>7</country>
<country>13</country>
</language>
<language>
<name>Spanish</name>
<country>1</country>
<country>2</country>
<country>3</country>
</language>
</languages>
</ResultSetStatus>
File1.1.xml
<ResultSetStatus State="Ready" PersistenceState="NotPersisted" TotalTradeCount="14" CompletedTradeCount="13" ErrorTradeCount="1" SensitivityErrorTradeCount="0" CalcServer="LDNDWM292011" LogFile="C:TEMPLogFilesExcelprocessor_9392.Flog3.log" BeginTimestamp="2012-09-18T15:17:15" EndTimestamp="2012-09-18T15:17:31
<Errors>
<Error>
<Severity>Warning</Severity>
<Source>EORE</Source>
<Id></Id>
<Message>EORE market data resolution warning: curve.swap/isk/reibo/* could not be mapped as the physical moniker was not resolvable.(object [official@20120824/curve.swap/emldnclose/isk/mid/reibor] not found in MX instance [me])</Message>
<ExtendedInfo></ExtendedInfo>
</Error>
<Error>
<Severity>Warning</Severity>
<Source>EORE</Source>
<Id></Id>
<Message>EORE market data resolution warning: curve.swap/nok could not be mapped as the physical moniker was not resolvable.(object [official@20120824/curve.swap/ldnficlose/nok/mid/nok6m ] not found in MX instance [me])</Message>
<ExtendedInfo></ExtendedInfo>
</Error>
<Errors>
<ResolvedTrades>
<Trade Moniker="ldn00c8f99a?version=45"/>
<Trade Moniker="ldn00c8ff71?version=53"/>
<Trade Moniker="ldn00c8ff72?version=48"/>
<Trade Moniker="ldn00c8fff0?version=49"/>
</ResolvedTrades>
<InputParameters>
<Trade Moniker="ldn00c8f99a?version=45"/>
<Trade Moniker="ldn00c8ff71?version=53"/>
<Trade Moniker="ldn00c8ff72?version=48"/>
<Trade Moniker="ldn00c8fff0?version=49"/>
</InputParameters>
<languages>
<language>
<name>English</name>
<country>8</country>
<country>9</country>
<country>3</country>
<country>11</country>
<country>12</country>
</language>
<languages>
</ResultSetStatus>
File1.3.xml
<ResultSetStatus State="Ready" PersistenceState="NotPersisted" TotalTradeCount="14" CompletedTradeCount="13" ErrorTradeCount="1" SensitivityErrorTradeCount="0" CalcServer="LDNDWM292011" LogFile="C:TEMPLogFilesExcelprocessor_9392.Flog3.log" BeginTimestamp="2012-09-18T15:17:15" EndTimestamp="2012-09-18T15:17:31
<Errors>
<Error>
<Severity>Warning</Severity>
<Source>EORE</Source>
<Id></Id>
<Message>EORE market data resolution warning: curve.swap/isk/reibo/* could not be mapped as the physical moniker was not resolvable.(object [official@20120824/curve.swap/emldnclose/isk/mid/reibor] not found in MX instance [me])</Message>
<ExtendedInfo></ExtendedInfo>
</Error>
<Error>
<Severity>Warning</Severity>
<Source>EORE</Source>
<Id></Id>
<Message>EORE market data resolution warning: curve.swap/nok could not be mapped as the physical moniker was not resolvable.(object [official@20120824/curve.swap/ldnficlose/nok/mid/nok6m ] not found in MX instance [me])</Message>
<ExtendedInfo></ExtendedInfo>
</Error>
<Errors>
<ResolvedTrades>
<Trade Moniker="ldn00c8f99a?version=45"/>
<Trade Moniker="ldn00c8ff71?version=53"/>
<Trade Moniker="ldn00c8ff72?version=48"/>
<Trade Moniker="ldn00c8fff0?version=49"/>
</ResolvedTrades>
<InputParameters>
<Trade Moniker="ldn00c8f99a?version=45"/>
<Trade Moniker="ldn00c8ff71?version=53"/>
<Trade Moniker="ldn00c8ff72?version=48"/>
<Trade Moniker="ldn00c8fff0?version=49"/>
</InputParameters>
<language>
<name>French</name>
<country>3</country>
<country>6</country>
<country>7</country>
<country>13</country>
</language>
</ResultSetStatus>
<!-- END -->[/code]
<br/>
View the full article
How do I copy part of xml from one xml to another. What I am doing here is to split 1 huge xml to another.
Say 600MB xmls into chunks of 6*100MB files. All 6 file need to have headers and standard set.
I have below XML , which I am trying to spli, however , I am unable to find a quick way to copy part of xml to another.
I do have a dll provided by internal tem
File 1.xml
<!-- ************** Block must go in all files -->
<ResultSetStatus State="Ready" PersistenceState="NotPersisted" TotalTradeCount="14" CompletedTradeCount="13" ErrorTradeCount="1" SensitivityErrorTradeCount="0" CalcServer="LDNDWM292011" LogFile="C:TEMPLogFilesExcelprocessor_9392.Flog3.log" BeginTimestamp="2012-09-18T15:17:15" EndTimestamp="2012-09-18T15:17:31
<Errors>
<Error>
<Severity>Warning</Severity>
<Source>EORE</Source>
<Id></Id>
<Message>EORE market data resolution warning: curve.swap/isk/reibo/* could not be mapped as the physical moniker was not resolvable.(object [official@20120824/curve.swap/emldnclose/isk/mid/reibor] not found in MX instance [me])</Message>
<ExtendedInfo></ExtendedInfo>
</Error>
<Error>
<Severity>Warning</Severity>
<Source>EORE</Source>
<Id></Id>
<Message>EORE market data resolution warning: curve.swap/nok could not be mapped as the physical moniker was not resolvable.(object [official@20120824/curve.swap/ldnficlose/nok/mid/nok6m ] not found in MX instance [me])</Message>
<ExtendedInfo></ExtendedInfo>
</Error>
<Errors>
<ResolvedTrades>
<Trade Moniker="ldn00c8f99a?version=45"/>
<Trade Moniker="ldn00c8ff71?version=53"/>
<Trade Moniker="ldn00c8ff72?version=48"/>
<Trade Moniker="ldn00c8fff0?version=49"/>
</ResolvedTrades>
<InputParameters>
<Trade Moniker="ldn00c8f99a?version=45"/>
<Trade Moniker="ldn00c8ff71?version=53"/>
<Trade Moniker="ldn00c8ff72?version=48"/>
<Trade Moniker="ldn00c8fff0?version=49"/>
</InputParameters>
<!-- ************** Block must go in all files -->
<!-- Below should split and copied into different files->
<languages>
<language>
<name>English</name>
<country>8</country>
<country>9</country>
<country>3</country>
<country>11</country>
<country>12</country>
</language>
<language>
<name>French</name>
<country>3</country>
<country>6</country>
<country>7</country>
<country>13</country>
</language>
<language>
<name>Spanish</name>
<country>1</country>
<country>2</country>
<country>3</country>
</language>
</languages>
</ResultSetStatus>
File1.1.xml
<ResultSetStatus State="Ready" PersistenceState="NotPersisted" TotalTradeCount="14" CompletedTradeCount="13" ErrorTradeCount="1" SensitivityErrorTradeCount="0" CalcServer="LDNDWM292011" LogFile="C:TEMPLogFilesExcelprocessor_9392.Flog3.log" BeginTimestamp="2012-09-18T15:17:15" EndTimestamp="2012-09-18T15:17:31
<Errors>
<Error>
<Severity>Warning</Severity>
<Source>EORE</Source>
<Id></Id>
<Message>EORE market data resolution warning: curve.swap/isk/reibo/* could not be mapped as the physical moniker was not resolvable.(object [official@20120824/curve.swap/emldnclose/isk/mid/reibor] not found in MX instance [me])</Message>
<ExtendedInfo></ExtendedInfo>
</Error>
<Error>
<Severity>Warning</Severity>
<Source>EORE</Source>
<Id></Id>
<Message>EORE market data resolution warning: curve.swap/nok could not be mapped as the physical moniker was not resolvable.(object [official@20120824/curve.swap/ldnficlose/nok/mid/nok6m ] not found in MX instance [me])</Message>
<ExtendedInfo></ExtendedInfo>
</Error>
<Errors>
<ResolvedTrades>
<Trade Moniker="ldn00c8f99a?version=45"/>
<Trade Moniker="ldn00c8ff71?version=53"/>
<Trade Moniker="ldn00c8ff72?version=48"/>
<Trade Moniker="ldn00c8fff0?version=49"/>
</ResolvedTrades>
<InputParameters>
<Trade Moniker="ldn00c8f99a?version=45"/>
<Trade Moniker="ldn00c8ff71?version=53"/>
<Trade Moniker="ldn00c8ff72?version=48"/>
<Trade Moniker="ldn00c8fff0?version=49"/>
</InputParameters>
<languages>
<language>
<name>English</name>
<country>8</country>
<country>9</country>
<country>3</country>
<country>11</country>
<country>12</country>
</language>
<languages>
</ResultSetStatus>
File1.3.xml
<ResultSetStatus State="Ready" PersistenceState="NotPersisted" TotalTradeCount="14" CompletedTradeCount="13" ErrorTradeCount="1" SensitivityErrorTradeCount="0" CalcServer="LDNDWM292011" LogFile="C:TEMPLogFilesExcelprocessor_9392.Flog3.log" BeginTimestamp="2012-09-18T15:17:15" EndTimestamp="2012-09-18T15:17:31
<Errors>
<Error>
<Severity>Warning</Severity>
<Source>EORE</Source>
<Id></Id>
<Message>EORE market data resolution warning: curve.swap/isk/reibo/* could not be mapped as the physical moniker was not resolvable.(object [official@20120824/curve.swap/emldnclose/isk/mid/reibor] not found in MX instance [me])</Message>
<ExtendedInfo></ExtendedInfo>
</Error>
<Error>
<Severity>Warning</Severity>
<Source>EORE</Source>
<Id></Id>
<Message>EORE market data resolution warning: curve.swap/nok could not be mapped as the physical moniker was not resolvable.(object [official@20120824/curve.swap/ldnficlose/nok/mid/nok6m ] not found in MX instance [me])</Message>
<ExtendedInfo></ExtendedInfo>
</Error>
<Errors>
<ResolvedTrades>
<Trade Moniker="ldn00c8f99a?version=45"/>
<Trade Moniker="ldn00c8ff71?version=53"/>
<Trade Moniker="ldn00c8ff72?version=48"/>
<Trade Moniker="ldn00c8fff0?version=49"/>
</ResolvedTrades>
<InputParameters>
<Trade Moniker="ldn00c8f99a?version=45"/>
<Trade Moniker="ldn00c8ff71?version=53"/>
<Trade Moniker="ldn00c8ff72?version=48"/>
<Trade Moniker="ldn00c8fff0?version=49"/>
</InputParameters>
<language>
<name>French</name>
<country>3</country>
<country>6</country>
<country>7</country>
<country>13</country>
</language>
</ResultSetStatus>
<!-- END -->[/code]
<br/>
View the full article