Skip to main content
Solved

I have connected to an AGOL feature service that includes attachments (pictures). I want to write each feature to its own excel document and include only the attachments for the respective feature.

  • November 29, 2020
  • 8 replies
  • 39 views

Forum|alt.badge.img+1

attachmentquestionPicture of my workbench attached. Can someone advise me on how to write out each feature to a separate excel sheet, and include only the attachments for the specific feature?

 

Thank You

Best answer by markatsafe

@vhruska13​  This workspace might be more useful as it uses AGOL as a data source

This post is closed to further activity.
It may be an old question, an answered question, an implemented idea, or a notification-only post.
Please check post dates before relying on any information in a question or answer.
For follow-up or related questions, please post a new question or idea.
If there is a genuine update to be made, please contact us and request that the post is reopened.

8 replies

Forum|alt.badge.img+2
  • 1891 replies
  • November 30, 2020

@vhruska13​ As a starting point, have a look at the article Writing Images to Microsoft Excel Spreadsheets


Forum|alt.badge.img+1
  • Author
  • 11 replies
  • November 30, 2020

@vhruska13​ As a starting point, have a look at the article Writing Images to Microsoft Excel Spreadsheets

Hey, so I have already had a bit of success with writing images to excel.

 

I should specify that my main question here is how to:

  • Separate attachments by feature (8 total in this case)
  • Write each feature to a separate excel document (8 total) with their respective attachments

I'm guessing this has something to do with a fanout setting, but I'm a bit confused on how this would be set up per feature.

 

If anyone could assist that would be great.

 

Thank You!


Forum|alt.badge.img+2
  • 1891 replies
  • November 30, 2020

@vhruska13​ Great. You're on the right track with fanout, but I think you're probably looking for the Dataset Fanout (as opposed to Feature Type fanout which gives you separate sheets). This is on the Excel writer (in the workbench Navigator). You can build up the Excel directory and file name form attributes in the workspace.


Forum|alt.badge.img+1
  • Author
  • 11 replies
  • December 1, 2020

@vhruska13​ Great. You're on the right track with fanout, but I think you're probably looking for the Dataset Fanout (as opposed to Feature Type fanout which gives you separate sheets). This is on the Excel writer (in the workbench Navigator). You can build up the Excel directory and file name form attributes in the workspace.

So I got the dataset fanout working like I want it to (kind of) - It writes an excel file for each feature in the dataset.

 

However, I now need to add the pictures into the specific excel sheet.

 

I'm pretty confused about where to configure the fanout settings after the list exploder and how to get the correct images into the sheet. Any tips?

Screenshot 2020-12-01 111901 

 

 


Forum|alt.badge.img+2
  • 1891 replies
  • December 1, 2020

@vhruska13​ You need the feature type to connect to the Featurewriter. But you probably don't really need the featureWriter and the AttributeFileWriter, You might just be able to replace that with the RasterReplacer, and replace the point geometry with the raster geometry.

One point to remember with the fanouts (both dataset and feature type ) Is that the attributes that you use for the fanout must be set on ALL the features you write to the output.

I've attached an example where I'm using a File Geodb + Attachments to write to Excel. In this case I have to use FeatureJoiner to ensure all the fanout attributes are on the image features. (i'm using feature type fanout instead of dataset fanout but th principal is the same.

Example workspace FME 2020.2


Forum|alt.badge.img+2
  • 1891 replies
  • Best Answer
  • December 1, 2020

@vhruska13​  This workspace might be more useful as it uses AGOL as a data source


Forum|alt.badge.img+1
  • Author
  • 11 replies
  • December 2, 2020

@vhruska13​  This workspace might be more useful as it uses AGOL as a data source

Mark - you're the man! Thank You. This works great. Although... I'm a little confused by how it works.

 

I've altered the workspace a bit to suit my dataset. Still a little confused on the images being carried over to excel. In the attached picture, are those fields the ONLY fields that are required to carry images over to excel? Can you elaborate?

 

Thanks for the patience - this is slowly starting to make sense.Screenshot 2020-12-01 221705


Forum|alt.badge.img+2
  • 1891 replies
  • December 2, 2020

Mark - you're the man! Thank You. This works great. Although... I'm a little confused by how it works.

 

I've altered the workspace a bit to suit my dataset. Still a little confused on the images being carried over to excel. In the attached picture, are those fields the ONLY fields that are required to carry images over to excel? Can you elaborate?

 

Thanks for the patience - this is slowly starting to make sense.Screenshot 2020-12-01 221705

@vhruska13​ Yes. pretty well only for the placement of the images. Excel is surprisingly complex!