Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Parsley, sage, rosemary
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Versions des environnements
Visual FoxPro:
VFP 9 SP2
OS:
Windows 8.1
Network:
Windows Server 2016
Database:
Visual FoxPro
Application:
Desktop
Divers
Thread ID:
01630685
Message ID:
01630715
Vues:
62
You misunderstood the message. See at the end

>I have to turn the ITEM_SECTION /ITEM_SECTION into 5 records, but I can't seem to be able to create the right schema file.
>Is it possible...can someone show me how to do that?
>Please note that I replaced the open tag with a "|", and the close tag with a "~" so I could post it.


He is asking how to parse this XML and the XML is the actual XML only changed for posting here.

>
>lcXML=CHRTRAN(lcData,"|~","<>")
>
>
>MartinaJ
>
>>Hi All,
>>
>>A customer has presented me with an XML file like the one below:
>>
>>|VFPData~
>> |dbftemp~
>> |EXPCONTACT~I:0#\NEOGIS01|/EXPCONTACT~
>> |CUST_2~NOC|/CUST_2~
>> |REFERENCE~NOC160128-080200|/REFERENCE~
>> |INV_DATE~2016-01-28|/INV_DATE~
>> |EXPORTER~TestCode|/EXPORTER~
>> |SHIPNAME~|/SHIPNAME~
>> |ITEM~
>> |ItemsSections~
>>
>>|ItemSection~|ItemSection_Item~SUJITH1234|/ItemSection_Item~|ItemSection_Quantity~30|/ItemSection_Quantity~|ItemSection_ItemBatchNo~|/ItemSection_ItemBatchNo~|ItemSection_NoOfBatches~123|/ItemSection_NoOfBatches~|ItemSection_ItemsPackagingDetails~|/ItemSection_ItemsPackagingDetails~|ItemSection_NoOfContainers~1|/ItemSection_NoOfContainers~|ItemSection_Therapeutic~Test;Test;test;Test|/ItemSection_Therapeutic~|ItemSection_FieldContainer~|/ItemSection_FieldContainer~|ItemSection_Hidden~0|/ItemSection_Hidden~|ItemSection_ItemContainer~|/ItemSection_ItemContainer~|/ItemSection~
>>
>>|ItemSection~|ItemSection_Item~SUJITH1234|/ItemSection_Item~|ItemSection_Quantity~30|/ItemSection_Quantity~|ItemSection_ItemBatchNo~|/ItemSection_ItemBatchNo~|ItemSection_NoOfBatches~123|/ItemSection_NoOfBatches~|ItemSection_ItemsPackagingDetails~|/ItemSection_ItemsPackagingDetails~|ItemSection_NoOfContainers~1|/ItemSection_NoOfContainers~|ItemSection_Therapeutic~Test;Test;test;Test|/ItemSection_Therapeutic~|ItemSection_FieldContainer~|/ItemSection_FieldContainer~|ItemSection_Hidden~0|/ItemSection_Hidden~|ItemSection_ItemContainer~|/ItemSection_ItemContainer~|/ItemSection~
>>
>>|ItemSection~|ItemSection_Item~TestCode|/ItemSection_Item~|ItemSection_Quantity~2|/ItemSection_Quantity~|ItemSection_ItemBatchNo~|/ItemSection_ItemBatchNo~|ItemSection_NoOfBatches~2|/ItemSection_NoOfBatches~|ItemSection_ItemsPackagingDetails~|/ItemSection_ItemsPackagingDetails~|ItemSection_NoOfContainers~1|/ItemSection_NoOfContainers~|ItemSection_Therapeutic~test;test;test;test|/ItemSection_Therapeutic~|ItemSection_FieldContainer~|/ItemSection_FieldContainer~|ItemSection_Hidden~0|/ItemSection_Hidden~|ItemSection_ItemContainer~|/ItemSection_ItemContainer~|/ItemSection~
>>
>>|ItemSection~|ItemSection_Item~TestCode|/ItemSection_Item~|ItemSection_Quantity~10|/ItemSection_Quantity~|ItemSection_ItemBatchNo~|/ItemSection_ItemBatchNo~|ItemSection_NoOfBatches~2|/ItemSection_NoOfBatches~|ItemSection_ItemsPackagingDetails~|/ItemSection_ItemsPackagingDetails~|ItemSection_NoOfContainers~2|/ItemSection_NoOfContainers~|ItemSection_Therapeutic~test;test;test;test|/ItemSection_Therapeutic~|ItemSection_FieldContainer~|/ItemSection_FieldContainer~|ItemSection_Hidden~0|/ItemSection_Hidden~|ItemSection_ItemContainer~|/ItemSection_ItemContainer~|/ItemSection~
>>
>>|ItemSection~|ItemSection_Item~SUJITH1234|/ItemSection_Item~|ItemSection_Quantity~1|/ItemSection_Quantity~|ItemSection_ItemBatchNo~|/ItemSection_ItemBatchNo~|ItemSection_NoOfBatches~2|/ItemSection_NoOfBatches~|ItemSection_ItemsPackagingDetails~|/ItemSection_ItemsPackagingDetails~|ItemSection_NoOfContainers~3|/ItemSection_NoOfContainers~|ItemSection_Therapeutic~test;test;test;test|/ItemSection_Therapeutic~|ItemSection_FieldContainer~|/ItemSection_FieldContainer~|ItemSection_Hidden~0|/ItemSection_Hidden~|ItemSection_ItemContainer~|/ItemSection_ItemContainer~|/ItemSection~
>>
>> |/ItemsSections~
>> |/ITEM~
>> |COMMENTS2~TestName TestBriefDescr;TestName TestDetail1;TestName TestDetail2;TestName TestDetail3|/COMMENTS2~
>> |PACKING~5|/PACKING~
>> |OCEAN~250|/OCEAN~
>> |SHPUM~TS TSD|/SHPUM~
>> |ENTRYDATE~2016-01-28|/ENTRYDATE~
>> |DETAILS2~TestName TestBriefDescr;TestName TestDetail1;TestName TestDetail2;TestName TestDetail3|/DETAILS2~
>> |MAN_PROC~TestName TestBriefDescr;TestName TestDetail1;TestName TestDetail2;TestName TestDetail3|/MAN_PROC~
>> |DOMESTIC~2|/DOMESTIC~
>> |INSURANCE~2|/INSURANCE~
>> |ASSIST~100|/ASSIST~
>> |FABRIC_CO~test mfg|/FABRIC_CO~
>> |YARN_CO~Test|/YARN_CO~
>> |SHIPPERSBN~\\FileShare\graphics\Images\imagename\test|/SHIPPERSBN~
>> |BUYERSBN~\\FileShare\graphics\Images\imagename\test|/BUYERSBN~
>> |FIBRE_CO~test|/FIBRE_CO~
>> |ISONUMBER~Test|/ISONUMBER~
>> |COMMISSION~10|/COMMISSION~
>> |DESC~TestCode|/DESC~
>> |CRTN~SUJITH1234|/CRTN~
>> |FACILITY~\\FileShare\graphics\Images\imagename\test|/FACILITY~
>> |EXPORT_CAR~TestFirstName TestMiddleName TestLastName |/EXPORT_CAR~
>> |PORT_ENTRY~TestCode|/PORT_ENTRY~
>> |HSCode~|/HSCode~
>> |MEAS~|/MEAS~
>> |CUSTOMER~SUJITH1234|/CUSTOMER~
>> |CUSTNAME~TestCode|/CUSTNAME~
>> |MISC~150|/MISC~
>> |email_address~|/email_address~
>> |/dbftemp~
>>|/VFPData~
>>
>>I have to turn the ITEM_SECTION /ITEM_SECTION into 5 records, but I can't seem to be able to create the right schema file.
>>Is it possible...can someone show me how to do that?
>>Please note that I replaced the open tag with a "|", and the close tag with a "~" so I could post it.
>>Thanks.
>>
>>Luke
If it's not broken, fix it until it is.


My Blog
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform