after get excel file from AWS, how to show data in excel file on Mendix?

0
hello guys.    I am trying to get file from AWS which is excel sheet. and I am trying to use excel importer to show data on excel file on Mendix.  this is what I  made microflow to get data on excel from AWS. for this, I have two question for you guys.  is this okay to show data on Excel?  if it is okay then what should I put argument below image?  thank you. :)   this is the detail information that I have concern. The current concerns I have are as follows: 1. I would like to check the existence of an Excel file in Mendix after getting it from AWS. 2. Additionally, I want to create the same template in Mendix based on the template inside the Excel file. 3. After creating the template, I would like to display all the original Excel information in the Mendix template. 4. It would be great if this process could be automated, so that whenever an Excel file is stored in AWS, the steps 1, 2, and 3 are repeated automatically.  
asked
2 answers
0

You are almost there.

  1. Your file i.e. the excel can reside anywhere. You have chosen AWS S3 which is ok.
  2. To get the file from AWS S3 you are using the correct module
  3. Once the file comes to Mendix runtime, now it needs parsing so that its Content can be READ and WROTE into the mendix domain model to represent it in a nice UI for your end customers. For this you are using ExcelImporter module that is also right
  4. So based on the excel files STRUCTURE(the sheets it has, the columns per sheet etc.) you first need to create a TEMPLATE in the ExcelImporter module provided pages
  5. Once the template is ready give it a good name which can be queried in the microflow
  6. This Microflow where the first part of the logic is to get the file from AWS S3 (can also be a SUB MF) and the second part is using ExcelImporter Module provided Java actions or Helper microflows to Parse it into your domain model
    1. while making the template you give the domain model entity, attributes to which you need yout excel data to be mapped
    2. this way the Template facilitates the data entry into the domain model when it gets parsed by the MFs/JA’s of the ExcelImporter module

The existence of the file can be checked by checking the GetObject Actions Responses. It will have properties that can be checked to see if some properties are usefull which indicates the file has contents (its size, name etc.)

 

Now about the automation part:

 

Since the Automation has to get triggered from the source, basically you need to setup some kind of event trigger to Call the mendix Microflow(which gets from S3, Parses, loads etc.) as soon as the FILE gets dropped in S3.

  1. Expose your microflow over a PUBLISHED REST SERVICE 
  2. Now setup AWS to trigger a AWS SNS notification on S3 PutObject(which gets fired when file gets dropped)
    1. as a target to this notification, you can put the REST Service made in Point 1 which gets triggered when the files gets placed

So ideally the flow is:

  1. Mendix is running by exposing a REST API (which underneath has your Microflow)
  2. AWS S3 has an event on PutObject to trigger AWS SNS Topic which has a Endpoint Trigger to the Endpoint exposed by Mendix

Find below some references:

Link
Link

https://docs.aws.amazon.com/sns/latest/dg/sns-http-https-endpoint-as-subscriber.html

Rather long but worth a shot :) Good luck​

answered
0

you are using Excel Importer. Excel importer is used to get the data into the mendix system. 

As per my understanding of your question, you want to export the AWS data to the end user. 

if my understanding is right, you should be using excel exporter and not importer. 

 

answered