Improving support for displaying data from XML subtrees
I am trying the software “birt-report-designer-all-in-one-4.9.0-20220315-linux.gtk.x86_64.zip” out also together with the following files.
Data source:
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<test_data>
<product>
<id>123</id>
<contributor>
<key>Test-Person1</key>
<name>Demo Check</name>
</contributor>
</product>
</test_data>
Query result preview:

Test result: The data from the XML area “contributor” are not shown (according to the XPath “/contributor” in relationship to the row mapping “/test_data/product”) so far.
:crystal_ball: Would it become possible to display the data of an XML subtree within a report list (without specifying corresponding elements explicitly)?
For complex objects (I mean: not scalar) it should possible to create a patch that displays the class of the object and (if it's a Java object) its toString() value. But I don't think that's a good idea, because if the XML is bigger than your tiny example (eg 20MB size) that output is unusable anyway - and it could result in OOM exceptions.
For complex objects (I mean: not scalar) it should possible to create a patch that displays the class of the object and (if it's a Java object) its toString() value.
Further software evolution would be nice in such a direction.
But I don't think that's a good idea, because if the XML is bigger than your tiny example
Data sizes will vary as usual.
that output is unusable anyway …
How do you think about to take any data size restrictions better into account?
Personally, I never use the "preview results", because it doesn't work anyway for the reports I develop. But I don't miss it. I am using BIRT to access JDBC data sets.
I used XML input only once several years ago and I faintly remember that it was quite hard to achieve what I wanted.
For XML input, I think it is much harder to restrict input size (compared with SQL).
I am referring to query result previews for such questionable software behaviour so that other open issues with report layout settings do not distract from more desirable solution ideas.
Note: "questionable" means "fragwürdig" in German - it has a negative connotation. Back to the initial question: What exactly would you expect to display for "contributor" - the whole XML subtree? Pretty-printed?
Can you provide a PR?
What exactly would you expect to display for "contributor" -
Further helpful information.
the whole XML subtree?
Yes. (For the data with which I am fiddling at the moment.)
Pretty-printed?
Dedicated data formatting would occasionally be nice.
Can you provide a PR?
Not directly.
I am unsure if circumstances will evolve in ways which will make contributions as pull/merge requests (from me) more likely.