0
votes

I have a need to export XML data, through the export scenario (E.g. NOT through Web service/endpoints).

How should the Data provider be set up?

In particular, what is the format for the schema attachment?

Don't suppose there is any ability to use an XSD? That would seem to be the "Standard" for working with XML, would seem more appropriate to use an XSD as the schema attachment...

Sample: I want to both import and export a structure similar to that generated by this SQL:

Select(
Select top 3
    BAccount.AcctCD As [CustomerID],
    BAccount.AcctName As [CustomerName],
    Customer.CustomerClassID  AS [CustomerClassID], 
    Customer.TermsID As [TermsID]
From
    Customer
    Inner Join BAccount On BAccount.BAccountID = Customer.BAccountID And BAccount.CompanyID = Customer.Companyid
Where Customer.Companyid > 0
for xml  Path(''), Type 
) AS Customers FOR XML PATH(''), TYPE, ELEMENTS

Which produces XML such as:

<Customers><CustomerID>ABCSTUDIOS</CustomerID><CustomerName>ABC Studios Inc</CustomerName><CustomerClassID>KEY</CustomerClassID><TermsID>30D</TermsID><CustomerID>ABARTENDE </CustomerID><CustomerName>USA Bartending School</CustomerName><CustomerClassID>KEY</CustomerClassID><TermsID>30D</TermsID><CustomerID>ACTIVESTAF</CustomerID><CustomerName>Active Staffing Service</CustomerName><CustomerClassID>LOCAL</CustomerClassID><TermsID>30D</TermsID></Customers>

Basically Customer ID, Name, Class, and Terms - Limited data set, since looking for the data provider

Have found the provider PX.DataSync.Xml - NO examples, though. Import/Export training seems to skip anything other than Excel / Sql server

2
Have reviewed: asiablog.acumatica.com/2016/08/… and help-2018r1.acumatica.com/Wiki/(W(4))/…. Neither seem to show "Complete" import schema OR the XML schema needed - user3708398

2 Answers

0
votes

There are two different types of format depending on whether you choose flat or tree format. See examples here

0
votes

https://feedback.acumatica.com/ideas/ACU-I-2663

Request XML export Redesign – It’s of VERY limited use. I’d expect to be given either a “Random-ish” file, or a spec of a file needed (I have a variety, or heck, use the sample I provided – Produce that XML). Usually the input / output CANNOT be modified, it’s provided from/to another party (or system). So design a way, compatible with the existing system, that allows a designer to specify the transition from/to a XML structure outside of your control

Nice if this included XSD as an option (Not always available, but can help in the what needed/provided) Also nice if have an ability to use an XSL transformation before and/or after (e.g. Especially if you need the format as you indicated, if I can indicate “Run XSL ?”, might be able to get it into that format) Current workaround: I’m trying to do this using the GIRO provider, and getting it right is challenging, don’t see a way around the “Extra” line feeds