I have a flow set up to run every Sunday as a 'Recurrence'.
The flow gets items from a SharePoint list and then emails various people the data contained within three calculated columns.
The calculated columns on SharePoint are 'Number' columns and have been set to zero decimal places.
However, when flow creates the email it adds numerous zeros to the figure it's taken from the list. Meaning, for example, that 37 is being shown as 37.0000000000000 on the email.
Can someone please assist me by advising how I can set the flow (or the SharePoint list) to only display the whole number, removing the decimal point and the thirteen zeros following it?
I have searched this site and others and have attempted various suggestions but none have worked and have either had no impact at all or have caused a flow error when saving or running the flow. I'm going around in circles now.
Please note, I'm new to this, so please forgive any apparently 'stupid' questions I might ask!
Thanks, Glen.
Solved! Go to Solution.
Hello @glenrennie
Use a compose action shape,
Than use the expression:
int()
—Josh
If you like my post please hit the "Thumbs Up" -- If my post solved your issue please "Mark as a Solution" to help others
Proud to be a Flownaut!
@glenrennie, @Jcook got there before me 😊 It should work fine with an int() expression. I put the calculated column, called Total, into a Compose called ComposeTotal and used the output of that in another Compose with the expression
And when you run the flow it strips put the decimal point and trailing zeros.
Rob
Los Gallardos
If I've answered your question or solved your problem, please mark this question as answered. This helps others who have the same question find a solution quickly via the forum search. If you liked my response, please consider giving it a thumbs up. Thanks.
Hello @glenrennie
Use a compose action shape,
Than use the expression:
int()
—Josh
If you like my post please hit the "Thumbs Up" -- If my post solved your issue please "Mark as a Solution" to help others
Proud to be a Flownaut!
Hi
As a fast workaround you can try to convert these 'Number' column values into string, and remove the decimal part.
Let's assume you store temporarily one of these Columns value in a variable called auxNumber
Then you can try with the following expression
first(split(string(variables('auxNumber')),'.'))
Hope this helps
Proud to be a Flownaut!
@glenrennie, @Jcook got there before me 😊 It should work fine with an int() expression. I put the calculated column, called Total, into a Compose called ComposeTotal and used the output of that in another Compose with the expression
And when you run the flow it strips put the decimal point and trailing zeros.
Rob
Los Gallardos
If I've answered your question or solved your problem, please mark this question as answered. This helps others who have the same question find a solution quickly via the forum search. If you liked my response, please consider giving it a thumbs up. Thanks.
…..however, I have three calculated columns to consider. The email is a reminder of paid leave days taken, days used and projected days left at the end of the year. So, I have three columns:
Do I need to create the two 'Compose' actions for each column, or can all three be combined into one?
Thanks, Glen .
I would have 3 compose shapes.
—Josh
If you like my post please hit the "Thumbs Up" -- If my post solved your issue please "Mark as a Solution" to help others
Proud to be a Flownaut!
You could possibly combine them but I'd have to think about how. Much easier just to use 2 compose controls for each one.
Rob
Los Gallardos
@Jcook @RobElliott - you guys are stars!
This fixed my issue perfectly, I should've come here first before spending hours driving myself mad! 🙄
Thanks a million!
Glen 🙂
So then what did you put in the email to get the number without trailing zeros?
The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.
Learn to digitize and optimize business processes and connect all your applications to share data in real time.
User | Count |
---|---|
31 | |
30 | |
29 | |
21 | |
11 |