Icon

XML Easy Reader demo - Jan 2022

XML Easy Reader demo
Annotations and comments
  • Basic 2-d "table" - simplest format can be loaded without any configuration
  • To quickly view (in default editor/browser) any of the xml files, configure the "Open File or Folder" component and enable (tick) the "Physically open... " box. Then execute the Open File or Folder component. The file will then be opened in your default viewer. With it "unticked", the component simply creates and passes the path as a flow variable to the XML Easy Reader component.
  • This example demonstrates a problem that is resolved by the next example!
  • Owner with Pets
  • Owner with Address
  • correct types
  • Some Animals have gone missing! And there's a mismatch of Animal with its name because of "optional" elements in the XML that Easy Reader cannot know about
  • Config restricts collection to only the //pets subtree along with elements outside of that subtree as defined under "key elements"
  • This time we have restricted the collection of elements by reference in the mapping file rather than by "collection subtree"
  • Easy Reader config made aware of "optional group elements" //pets/pet so pets and their names now match up
  • (workaround: Remove superfluous "del:" columns that have been included in mapping file to avoid name clash)
  • clear "empty" cells
  • remove grouping columns
  • takbb-opener-enabled
  • takbb-workflow-data-create
  • Request to create "data" folder?
  • Collect Allowed OutputNames
  • Create Data folder
  • Collect workflow context information
  • Gets absolute path to location. If "enabled" is set on config, open's that location in associated application
  • Define an outputfile string flow variable relative relative to workflow
  • takbb-location-type
  • takbb-opener-location
  • takbb-flowvar
  • Unpack everything Straight unpack DOESN'T "fill down" !!
  • Unpack address so they "fill down"
  • Unpack top level
  • Unpack pets so they "fill down" But notice how the "optional" elements in the pets grouping has meant a mismatch in data so "Bugsy" the rabbit, has the breed "Cross-eyed Lion", which actually should attributed to Clarence the Cat
  • unpack everything
  • Unpack pets so they "fill down"
  • Unpack streets and towns so they "fill down"
  • Unpack pets so they "fill down" Clarence is now the Cross Eyed Lion, because of config change on the Easy Reader component
  • Dummy Node Row filter has turned off auto ungroup
  • auto-delete-empty-columns
  • full-column-names
  • auto-group-pad
  • Split cell values on ¬|¬ delimiter
  • Loop through columns
  • rename the columns
  • Mark anything totally empty as missing
  • collect
  • Whether to auto delete empty columns
  • Whether to auto ungroup columns
  • Upper port (Port 0) - use names from the Python output port (rename columns) Port 1 - use full column names (do nothing)
  • Upper port (Port 0) - use names from the Python output port (rename columns) Lower port (Port 1) - use full column names (do nothing)
  • Read the xpath file
  • Turn into S[] array
  • Create columns as list
  • Create column grouping lists
  • Create column list
  • Keep only required columns
  • Rename grouping columns
  • Friendly names to variables
  • Test for name clash
  • New course of action as no unpacking to do
  • End switch option
  • Get count of groupings
  • User supplied xsd or xpath file?
  • Get column groupings
  • Maximum Auto Unpack Threshold
  • first-n-rows
  • Get column group for this iteration
  • auto-ungroup to 0
  • If there is only one grouping set unpack threshold so that it is ungrouped
  • Decide the switch condition
  • Remove columns found to be empty (all rows missing)
  • Read the XML file and output required columns
  • Output only clashing names
  • Row filter for debugging purposes
  • Auto unpack threshold cutoff
  • Sort descending TreeDepth
  • Sort into descending depth size
  • root-element-name
  • row-element-name
  • sub-tree-element-name
  • row-identifier
  • collection-subtree
  • optional element groups
  • unpack-exclusion-list
  • xml-file-path
  • column-path-file
  • Get Column Names from ROWID
  • TreeDepth to Int for sorting
  • Get location of xpath_file as a Path variable
  • Create ungroup sequence variable
  • Bacl to variable so it can be used by ungroup
  • Make the EasyXML: variables
  • How many groupings?
  • Element Depth transposition
  • One column per group
  • Prepare to make into variable
  • Column Grouping list as one column
  • Make into columns so they can be turned into S[] array

Nodes

Extensions

Links