I've attached two files. The first one is INVOICE, that is generated by every establishment when you purchase, and is in xml format.
The second one is XSLT file, that is provided by government fiscal institution and is used to "translate" xml.
PROBLEM DESCRIPTION: when I try to decode xml using attached xslt scheme on any online xml-converter website the output looks fine. BUT when importing to Filemaker, I receive an error: "XML parsing error: invalid document structure".
I would appreciate any help with the issue. Thanks.
By Jeff M
I've done quite a bit with FileMaker in the past, but have never jumped into the XML arena. Now I have a need to do so, and I'm really needing some help with something I'm sure is quite basic...but still foreign to me. I have an external data source which export XML in a very specific format (see attached). I need to import that into FileMaker so I can manipulate the data, do some various lookups, etc. Once I've made my changes in the data, I need to export in the exact format it was when imported so the external data source can properly import.
Not sure if it makes sense to import into 2 tables (workflows, workflow steps) or just a single table. I'm open either way. Once the data is in FileMaker I can get all my calculations and lookups and scripts going and make the data what I need it to be, but then I'll need to export it.
Can someone point me in the right direction?
Thanks so much in advance!
By Andreas T.
I need some help in determining if I am missing something crucial here or if there is a limitation or bug in the function BE_ApplyXSLT from the BaseElements plugin. I am using version 3.3.4 (which is the latest) on Mac OS X 10.11.6 using FileMaker 15 Adv. and 16 Adv.
I am unable to get any output from the transformation, nor any error.
According to the documentation, the command shall return either 0 when successful or an error. Link
In my testing it only returns blank, and gives no error even when no output file is generated. It should not return blank in cany case according to the docs. (I suspect there may be a documentation error and that it actually returns blank when there is no error.)
No error is found using Get(LastError). BE_GetLastError returns 0.
The function format is this:
BE_ApplyXSLT ( xmlPath ; xslt ; outputPath ) Here are the input parameters I have used:
BE_ApplyXSLT ( "/var/folders/y6/1yf76qcs5y91h_w4j27hxp980000gp/T/S10.2/ABC_nota_108.xml" ; BE_ReadTextFromFile ( "/var/folders/y6/1yf76qcs5y91h_w4j27hxp980000gp/T/S10.2/HTMLvisning/Stylesheet_Full.xsl" ); "/var/folders/y6/1yf76qcs5y91h_w4j27hxp980000gp/T/S10.2/output.html" ) I have verified that the files exist and that both the XML and XSLT are valid. All files are in UTF-8. I can transform the XML with this XSLT using other
methods without errors. I have also tried having the XSLT in a variable.
As I understand it, BaseElements uses the libxml2 engine. I have tried doing the transform from the command line directly and it works as it should:
xsltproc -o /var/folders/y6/1yf76qcs5y91h_w4j27hxp980000gp/T/S10.2/output.html /var/folders/y6/1yf76qcs5y91h_w4j27hxp980000gp/T/S10.2/HTMLvisning/Stylesheet_Full.xsl /var/folders/y6/1yf76qcs5y91h_w4j27hxp980000gp/T/S10.2/ABC_nota_108.xml It also works fine using the XMLLib OSAX in AppleScript. Unfortunately, I need Windows support also so I would like to get the BaseElements function to work.
I hope somone can shed some light on what may be going on.
I am having some trouble getting my XSLT file to work. I have followed many of the posts on here and have referenced
I seem to be able to get the examples to work and have had success with the example files for metars.cache.xml weather meter readings, but can't see why my own isn't working properly when it looks the same to me. Any guidance would be gratefully received. I am not new to Filemaker but this is my first attempt at importing and exporting data to/from our solution in XML which meets the UK Government standards. My XSLT seems only to match fields but not actually import and records. I have attempted referencing the template match to root with <xsl:template match="/Message"> but this causes an "Invalid Document Structure" error in Filemaker, which doesn't seem to be a problem with the w3schools try xslt page. I have reverted back to the format in the meters.xslt example file and now hope that somebody can help!!
Hi everyone. Could someone help me? I am so close to having this working and we've spent the last two days trying everything, and we're stumped. We built this xslt template and it's associated xml file... and filemaker opens up like it's all good, allows me to map the fields, all good, then we hit import and it only does one file and there is no data in any of the fields. These two files are the short sanitized version of the data, the original xml has 600 records... but this is exactly the structure, and I'm wondering if anyone can tell us what we are missing.? Again, no data arrives in the record, and it only does one record even thou we have 600. (I know this one will only be a single record).
Any guidance from the group would be so appreciated. Thanks.