Showing results for 
Search instead for 
Did you mean: 
Kudo Collector
Kudo Collector

Sharepoint List to Html Table in Send email



can anybody tell me what is to correct way to parse a SHP List with 20+ colls in a way that only selected collumns are outputted to a html table in a send mail action. I want to create a flow that runs daily to send summary emails (and no, SHP alerts are not a acceptable workaround 😞 also It needs to be in one email only).


Rant: Shouldnt this be trivial? I have spent more than 3hours trying to piece this together 😞 unfortunately I am unable to find reference for Data operations Actions (can anyone please point me to the right direction, I would doubly appreciate if it had ms flow ready examples) /endrant


I have tried multiple combinations, the one that makes the most sense:




Accepted Solutions
Regular Visitor

Use the Select action from Data Operations. Below is part of a flow that emails me my active (that's what the filter is for) planner tasks.


Send Task List.png

View solution in original post

Community Support
Community Support

Hi @avt,


Have you checked the Create HTML table Action?

A better way is use the Create HTML table Action to build the table, if you only need to send the HTML body to yourself, then choose the Send me Email Notification action, if others would be involved, change it to the Send an Email Action.

For Send an Email Action, make sure the Is HTML is set to Yes under Advanced options.



If you need any further help on this, please post back.



Community Support Team _ Michael Shao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Thank you, but as I said I need only selected collums not all of them because the list has 20+ colls and the formating is terrible with more than ten.


I can select the wanted collumns with the Compose Action in Aplly to each container but cannot merge them into a single table after that with Join Action.


Funny enough the Join Action works ok If I skip the Compose Action but than once again I am stuck with all the inwanted collums, is this a bug? (The invalid template error in screenshot in my first post)

Regular Visitor

Use the Select action from Data Operations. Below is part of a flow that emails me my active (that's what the filter is for) planner tasks.


Send Task List.png

View solution in original post

Kudo Collector
Kudo Collector

Thank you, it worked, its perfect, you saved my day 🙂

Not applicable

I just built this exact example flow with a few more conditions, trying to figure out in the above if I wanted to compose the due date into a nicer looking format, how I could pull that off for each table entry.

Not applicable

 Nevermind, I dfigured this out. Instead of having it compase seperately, I added the following directly into the table:



works nicely as long as there is a due date attached, working on a conditional statement now for when it is empty, still not working quite right.


Try this. It shows N/A if there's no due date. You need the second coalesce() since the false option is still evaluated in the if function.





I am writing rows from an Excel spreadsheet to a HTML table that will be sent via email. I understand you were able to modify the format of the date by directly entering the format code into the table? I'm not sure I know how to do this - could you take a look at my current flow and help me determine where to place the format code (I currently have it in the Compose action which is not working)? Thanks in advance




Not applicable


I wrote the code directly into the box on the 'Select' area:

@if(equals('01/01/2000',formatDateTime(coalesce(item()?['dueDateTime'],'2000-01-01T00:01:00Z'),'MM/dd/yyyy')),'Not Set',formatDateTime(coalesce(item()?['dueDateTime'],'2000-01-01T00:01:00Z'),'MM/dd/yyyy'))


I made it conditional, as in my case I was pulling a date from a Task due date, which may or may not be assigned.


Hit the x to remove the variable below in the field you want to compose the date, and insert your code directly into the table on the 'Select' area. Eliminate the compose completely.





Thank you for your quick reply. I attempted to insert the format line into the Select action, but my results are unexpected. I'm assuming I need to adjust the format line so that the format line is read as a function as opposed to text. Do you know if I need to tweak the format line so that it works properly?


Here's my Select action:



And here's an example from the output:







Output table.PNG

Not applicable

Hmm, I don;t remember exactly, but I may have switched into the advanced mode to insert the code there before saving. Made sure to add the open/close quotes around it to when inserting.


Edit: Also, are you sure the name of the value is Blocked_Date? I havn't seen that format yet, if unsure, add it to the table in the GUI, and then switch into advanced mode to see its real name.

@Anonymous, thank you for your continued help. I finally figured out it after looking at the syntax of the formateDateTime function. I had some curly brackets inserted incorrectly and now it is performing correctly. Here's the new line that works: 

Not applicable

How it's possible to get Data Operator "Select" MAP values using Recurrence trigger (or what is that)? Are these dynamic?
I can't find a solution to get the wanted values in to the table, without FOR EACH function. Any help?


I have implemented the solution as indicated and I am still getting the problem of all the fields from my SharePoint list appearing in the body of the email. What am I missing or not doing?


Has anyone created this successfully pulling data from a SharePoint list?

Not applicable

I don't remember all my tests, but at the end I have created CSV table and got filtered sharepoint list table in my approval email. I add flow steps and email screenshot. 


How are you able to create your Select not within Apply to each block?


My logic looks like this:

Recurrence --> Get Items --> Filter Array --> Apply to each --> Select --> Create HTML Table --> Send Email


The Select is nested within the Apply to each but it should be like yours and exist outside of it. I tried to do it that way but when I select the output from Filter Array as the input to Select, it automatilcally nests in within the Appy to each.

Not applicable

As I remember the "trick" I have done:
In the Select action, for the first time adding the *From field, should not be used the Fillter array body, but Get items value. Further, in the *Map fields select necessary culumns from  "Get items".
Save the flow. 
After that, you need to edit a flow and modify Select action's *From field. For that, delete Get items value and put previous Filter array Body. In this case apply to each action won't appear. 

Thank you so much for that! I implemented your changes and my flow works correctly now!


@Anonymous, thank you so much for this "trick"! I've been beating my head against a wall for days trying to figure out how to keep the For Each from being added to my Select. One note to add. As I've been working on it further, I've found that any time I need to bake edits tot he mapping of the Select, I need to once again change the From back to the Get Items... make my mapping edits... then change the From back to the Filter Body. If don't do that it adds the dreaded For Each, then I have to start over again with my Select.

Helpful resources

2022 Release Wave 1 760x460.png

2022 Release Wave 1 Plan

Power Platform release plan for the 2022 release wave 1 describes all new features releasing from April 2022 through September 2022.

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

User Group Leader Meeting January 768x460.png

Calling all User Group Leaders!

Don't miss the User Group Leader meetings on January, 24th & 25th, 2022.

Top Solution Authors
Top Kudoed Authors
Users online (2,549)