Question

Summary reporting using AttribuetPivoter and excel writer not working as expected

  • 24 May 2019
  • 1 reply
  • 0 views

I am running a summary worksheet which basically identifies all the features which are tagged with the input catchment ID and then puts them through an attribute pivoter with rows grouped by the ID and columns grouped by landuse type and the area of these features are analysed.

The output of this pivoter is written using an XLSX writer with a dynamic definition as that seems to be the only way I can access the table that the pivoter outputs. The output works great:

IDRuralUrbanWaterGW01209320098

 

So I run this workflow using a workspace runner where the user can select a number of catchments to produce a report for. The workspace is run for each catchment ID. All the runs write into the same excel worksheet, with a new row for each catchment ID being added for each run. This works, however each run seems to consider columns in isolation of what is already in the worksheet. e.g.

IDRuralUrban WaterGW012093

 

200

 

98

 

GW023870105

 

In this example GW02 doesn't actually have any urban landuses and is writing into the workspace like this:

GW023870105

It is not checking what is already in the worksheet and is making its own columns regardless of what is already there.

 

Is there a way I can get the writer to update into an already existing worksheet and add new columns when necessary?


1 reply

Badge +2

@em_fme I couldn't reproduce your problem. I've attached an FME workspace (2019) that creates the two rows that you have in your example and the columns seem to line-up correctly.

You mentioned using Dynamic Mode, so perhaps if you want to modify this workspace a little to reproduce the issue someone can take another look. Workspace (2019) excelupdates.fmw

Reply