cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
rschneider
Advocate III
Advocate III

Create HTML table and select fail when individual cells blank

 I keep getting the "invalid template" error when just one field in one row is blank when using the action "select" or "create html table". How do I get around this? I don't mind blank cells in the table.

1 ACCEPTED SOLUTION

Accepted Solutions

Hi!

So i guess the problem is with 

item()['KategorieManager']['DisplayName']

since sometimes KategorieManager does not exist.

I would suggest to replace the current expression and use this one instead:

coalesce(item()['KategorieManager']['DisplayName'],'')

using coalesce() with two parameters, if first parameter is null, then second parameter is applied.

Hope this helps

 



Each time you click on any of our inspiring answers 'Thumb up' icon...
...an ewok scapes from the stormtroopers.

Be grateful, Thumbs up! Save the Galaxy for free!


Escribo sobre Power Automate en:
https://medium.com/anyone-can-automate/

Proud to be a Flownaut!



View solution in original post

5 REPLIES 5
efialttes
Super User
Super User

Hi!

Can you share a screenshot from your Select, also share expressions if you are using them? And also can you point us which is the field that sometimes is empty?

thanx!



Each time you click on any of our inspiring answers 'Thumb up' icon...
...an ewok scapes from the stormtroopers.

Be grateful, Thumbs up! Save the Galaxy for free!


Escribo sobre Power Automate en:
https://medium.com/anyone-can-automate/

Proud to be a Flownaut!



The error is as follows:

invalid template.png

 

 

In this case I use the select to create the html table and then send that in an email.
If the rows in my source contain no blanks, I do not get this error! This leads me to believe my expressions are valid.
expressions.png

 

Hi!

So i guess the problem is with 

item()['KategorieManager']['DisplayName']

since sometimes KategorieManager does not exist.

I would suggest to replace the current expression and use this one instead:

coalesce(item()['KategorieManager']['DisplayName'],'')

using coalesce() with two parameters, if first parameter is null, then second parameter is applied.

Hope this helps

 



Each time you click on any of our inspiring answers 'Thumb up' icon...
...an ewok scapes from the stormtroopers.

Be grateful, Thumbs up! Save the Galaxy for free!


Escribo sobre Power Automate en:
https://medium.com/anyone-can-automate/

Proud to be a Flownaut!



View solution in original post

@efialttes 
Great! I think that will solve the issue quite nicely. Unfortunately, I will probably have to do that for every column... But that is a limitation of the flow!
Thank you very much!

@rschneider 

Thanx for your kindness! Your issue was really well documented, so it has been easy to provide a useful answer.

Happy flowing!



Each time you click on any of our inspiring answers 'Thumb up' icon...
...an ewok scapes from the stormtroopers.

Be grateful, Thumbs up! Save the Galaxy for free!


Escribo sobre Power Automate en:
https://medium.com/anyone-can-automate/

Proud to be a Flownaut!



Helpful resources

Announcements
UG GA Amplification 768x460.png

Launching new user group features

Learn how to create your own user groups today!

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

M365 768x460.jpg

Microsoft 365 Collaboration Conference | December 7–9, 2021

Join us, in-person, December 7–9 in Las Vegas, for the largest gathering of the Microsoft community in the world.

Top Solution Authors
Users online (2,792)