Leer Xml
Me gustaría saber si me puedes ayudar, tengo un archivo xlm que requiero leer desde visual foxpro 9, estuve mirando en internet y encontré esta función: xmltocursor. El problema es que cuando la ejecuto me marca el siguiente error: XML Parse error: Declaración xml no válida. Line 3, position 3 <?xml version="1.0" encoding="UTF-8"?>.
Yo estoy escribiendo lo siguiente: XMLTOCURSOR("oc_xml.xml","MiCursor", 512)
Y he estado mirando en internet pero no he encontrado solución.
El archivo es así:
<?xml version="1.0" encoding="UTF-8" ?>
- <eanucc:envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:eanucc="http://www.uc-council.org/smp/schemas/eanucc" xmlns:fmcg="http://www.uc-council.org/smp/schemas/fmcg" xsi:schemaLocation="http://www.uc-council.org/smp/schemas/eanucc As2Envelope.xsd http://www.uc-council.org/smp/schemas/eanucc Transaction.xsd http://www.uc-council.org/smp/schemas/eanucc DocumentCommand.xsd http://www.uc-council.org/smp/schemas/eanucc Order.xsd http://www.uc-council.org/smp/schemas/fmcg FmcgIdentification.xsd" communicationVersion="1.0">
- <messageHeader creationDate="2010-02-02T00:00:00">
<userId>CEN</userId>
<password>PEDIDOS</password>
<messageIdentifier>142-131</messageIdentifier>
- <to>
<gln>7709999008174</gln>
</to>
- <from>
<gln>7707185370005</gln>
</from>
- <representingParty>
<gln>NORMANETCEN01</gln>
</representingParty>
</messageHeader>
-
<body>
- <eanucc:transaction>
- <entityIdentification>
<uniqueCreatorIdentification>142-131</uniqueCreatorIdentification>
- <contentOwner>
<gln>7707185370005</gln>
</contentOwner>
</entityIdentification>
- <command>
- <eanucc:documentCommand>
- <documentCommandHeader type="ADD">
- <entityIdentification>
<uniqueCreatorIdentification>142-131</uniqueCreatorIdentification>
- <contentOwner>
<gln>7707185370005</gln>
</contentOwner>
</entityIdentification>
</documentCommandHeader>
- <documentCommandOperand>
- <eanucc:order documentStatus="ORIGINAL" creationDate="2010-02-02T00:00:00">
-
<paymentTerms type="DISCOUNT" eventType="DATE_INVOICE_RECEIVED">
- <netPayment>
<timePeriodDue type="DAYS">30</timePeriodDue>
</netPayment>
</paymentTerms>
<movementDate>2010-02-02</movementDate>
<movementDateType>REQUESTED_PICKUP</movementDateType>
- <typedEntityIdentification entityType="ORDER">
- <entityIdentification>
<uniqueCreatorIdentification>142-131</uniqueCreatorIdentification>
- <contentOwner>
<gln>7707185370005</gln>
</contentOwner>
</entityIdentification>
</typedEntityIdentification>
- <buyer>
<gln>7707185370005</gln>
</buyer>
- <seller>
<gln>7709999008174</gln>
</seller>
- <shipParty identificationType="SHIP_TO">
<gln>7707185371422</gln>
</shipParty>
-
<lineItem number="1">
- <netPrice>
<amount currencyISOcode="">16,679.00</amount>
</netPrice>
<requestedQuantity>2</requestedQuantity>
- <itemIdentification>
<gtin>7702057071813</gtin>
</itemIdentification>
</lineItem>
-
<lineItem number="2">
- <netPrice>
<amount currencyISOcode="">6,006.00</amount>
</netPrice>
<requestedQuantity>2</requestedQuantity>
- <itemIdentification>
<gtin>7702057124021</gtin>
</itemIdentification>
</lineItem>
-
<lineItem number="3">
- <netPrice>
<amount currencyISOcode="">26,391.00</amount>
</netPrice>
<requestedQuantity>2</requestedQuantity>
- <itemIdentification>
<gtin>7707172687802</gtin>
</itemIdentification>
</lineItem>
-
<lineItem number="4">
- <netPrice>
<amount currencyISOcode="">15,620.00</amount>
</netPrice>
<requestedQuantity>2</requestedQuantity>
- <itemIdentification>
<gtin>7702132007041</gtin>
</itemIdentification>
</lineItem>
-
<lineItem number="5">
- <netPrice>
<amount currencyISOcode="">5,597.00</amount>
</netPrice>
<requestedQuantity>3</requestedQuantity>
- <itemIdentification>
<gtin>77014535</gtin>
</itemIdentification>
</lineItem>
-
<lineItem number="6">
- <netPrice>
<amount currencyISOcode="">5,224.00</amount>
</netPrice>
<requestedQuantity>4</requestedQuantity>
- <itemIdentification>
<gtin>7702057168049</gtin>
</itemIdentification>
</lineItem>
-
<lineItem number="7">
- <netPrice>
<amount currencyISOcode="">3,765.00</amount>
</netPrice>
<requestedQuantity>4</requestedQuantity>
- <itemIdentification>
<gtin>7703381002382</gtin>
</itemIdentification>
</lineItem>
-
<lineItem number="8">
- <netPrice>
<amount currencyISOcode="">11,874.00</amount>
</netPrice>
<requestedQuantity>4</requestedQuantity>
- <itemIdentification>
<gtin>7702870999745</gtin>
</itemIdentification>
</lineItem>
-
<lineItem number="9">
- <netPrice>
<amount currencyISOcode="">3,688.00</amount>
</netPrice>
<requestedQuantity>4</requestedQuantity>
- <itemIdentification>
<gtin>7702123832645</gtin>
</itemIdentification>
</lineItem>
-
<lineItem number="10">
- <netPrice>
<Amount...
Yo estoy escribiendo lo siguiente: XMLTOCURSOR("oc_xml.xml","MiCursor", 512)
Y he estado mirando en internet pero no he encontrado solución.
El archivo es así:
<?xml version="1.0" encoding="UTF-8" ?>
- <eanucc:envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:eanucc="http://www.uc-council.org/smp/schemas/eanucc" xmlns:fmcg="http://www.uc-council.org/smp/schemas/fmcg" xsi:schemaLocation="http://www.uc-council.org/smp/schemas/eanucc As2Envelope.xsd http://www.uc-council.org/smp/schemas/eanucc Transaction.xsd http://www.uc-council.org/smp/schemas/eanucc DocumentCommand.xsd http://www.uc-council.org/smp/schemas/eanucc Order.xsd http://www.uc-council.org/smp/schemas/fmcg FmcgIdentification.xsd" communicationVersion="1.0">
- <messageHeader creationDate="2010-02-02T00:00:00">
<userId>CEN</userId>
<password>PEDIDOS</password>
<messageIdentifier>142-131</messageIdentifier>
- <to>
<gln>7709999008174</gln>
</to>
- <from>
<gln>7707185370005</gln>
</from>
- <representingParty>
<gln>NORMANETCEN01</gln>
</representingParty>
</messageHeader>
-
<body>
- <eanucc:transaction>
- <entityIdentification>
<uniqueCreatorIdentification>142-131</uniqueCreatorIdentification>
- <contentOwner>
<gln>7707185370005</gln>
</contentOwner>
</entityIdentification>
- <command>
- <eanucc:documentCommand>
- <documentCommandHeader type="ADD">
- <entityIdentification>
<uniqueCreatorIdentification>142-131</uniqueCreatorIdentification>
- <contentOwner>
<gln>7707185370005</gln>
</contentOwner>
</entityIdentification>
</documentCommandHeader>
- <documentCommandOperand>
- <eanucc:order documentStatus="ORIGINAL" creationDate="2010-02-02T00:00:00">
-
<paymentTerms type="DISCOUNT" eventType="DATE_INVOICE_RECEIVED">
- <netPayment>
<timePeriodDue type="DAYS">30</timePeriodDue>
</netPayment>
</paymentTerms>
<movementDate>2010-02-02</movementDate>
<movementDateType>REQUESTED_PICKUP</movementDateType>
- <typedEntityIdentification entityType="ORDER">
- <entityIdentification>
<uniqueCreatorIdentification>142-131</uniqueCreatorIdentification>
- <contentOwner>
<gln>7707185370005</gln>
</contentOwner>
</entityIdentification>
</typedEntityIdentification>
- <buyer>
<gln>7707185370005</gln>
</buyer>
- <seller>
<gln>7709999008174</gln>
</seller>
- <shipParty identificationType="SHIP_TO">
<gln>7707185371422</gln>
</shipParty>
-
<lineItem number="1">
- <netPrice>
<amount currencyISOcode="">16,679.00</amount>
</netPrice>
<requestedQuantity>2</requestedQuantity>
- <itemIdentification>
<gtin>7702057071813</gtin>
</itemIdentification>
</lineItem>
-
<lineItem number="2">
- <netPrice>
<amount currencyISOcode="">6,006.00</amount>
</netPrice>
<requestedQuantity>2</requestedQuantity>
- <itemIdentification>
<gtin>7702057124021</gtin>
</itemIdentification>
</lineItem>
-
<lineItem number="3">
- <netPrice>
<amount currencyISOcode="">26,391.00</amount>
</netPrice>
<requestedQuantity>2</requestedQuantity>
- <itemIdentification>
<gtin>7707172687802</gtin>
</itemIdentification>
</lineItem>
-
<lineItem number="4">
- <netPrice>
<amount currencyISOcode="">15,620.00</amount>
</netPrice>
<requestedQuantity>2</requestedQuantity>
- <itemIdentification>
<gtin>7702132007041</gtin>
</itemIdentification>
</lineItem>
-
<lineItem number="5">
- <netPrice>
<amount currencyISOcode="">5,597.00</amount>
</netPrice>
<requestedQuantity>3</requestedQuantity>
- <itemIdentification>
<gtin>77014535</gtin>
</itemIdentification>
</lineItem>
-
<lineItem number="6">
- <netPrice>
<amount currencyISOcode="">5,224.00</amount>
</netPrice>
<requestedQuantity>4</requestedQuantity>
- <itemIdentification>
<gtin>7702057168049</gtin>
</itemIdentification>
</lineItem>
-
<lineItem number="7">
- <netPrice>
<amount currencyISOcode="">3,765.00</amount>
</netPrice>
<requestedQuantity>4</requestedQuantity>
- <itemIdentification>
<gtin>7703381002382</gtin>
</itemIdentification>
</lineItem>
-
<lineItem number="8">
- <netPrice>
<amount currencyISOcode="">11,874.00</amount>
</netPrice>
<requestedQuantity>4</requestedQuantity>
- <itemIdentification>
<gtin>7702870999745</gtin>
</itemIdentification>
</lineItem>
-
<lineItem number="9">
- <netPrice>
<amount currencyISOcode="">3,688.00</amount>
</netPrice>
<requestedQuantity>4</requestedQuantity>
- <itemIdentification>
<gtin>7702123832645</gtin>
</itemIdentification>
</lineItem>
-
<lineItem number="10">
- <netPrice>
<Amount...
1 Respuesta
Respuesta de Alonso Jarrín Solís
1