web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Determine string lengt...
Power Automate
Answered

Determine string length, to apply rounding new column ( using SharePoint Online & Power Automate)

(0) ShareShare
ReportReport
Posted on by 21

I have two columns sample below, I need to round the second column string to the same length as in the first column to be able to automate order placing.

 

Current Price:       Order Price:

0.123                     0.134768

1.1                         1.243029

0.00045                  0.000472

 

The outcome I would like to see is:

Current Price:       Order Price:

0.123                     0.135

1.1                         1.2

0.00045                 0.00047

 

Thanks

 

Categories:
I have the same question (0)
  • eviljoen4 Profile Picture
    21 on at

    I thought this might work but as @VictorIvanidze pointed out it does not work in all scenarios

    =ROUND(['Order Price'],LEN(Current Price)-2)

  • VictorIvanidze Profile Picture
    13,073 on at

    Hi @eviljoen4,

     

    what if CurrentPriice is 123.123 and OrderPrice is 122.22222 ?

  • eviljoen4 Profile Picture
    21 on at

    Hello,

     

    Good question, let me check.

     

  • eviljoen4 Profile Picture
    21 on at

    You correct my solution does not work, any ideas?

  • Verified answer
    Shujaath_Khan Profile Picture
    1,111 Super User 2024 Season 1 on at

    Hi @eviljoen4 

     

    there's good thread on round here

    tried substring way if you're interested you can try  below expression but the problem is it doesn't round the value

    concat(split(variables('varorderPrice'),'.')[0],'.',substring(split(variables('varorderPrice'),'.')[1],0,length(split(variables('varCurrentPrice'),'.')[1])))

     

    Thanks

    Please click Accept as Solution on this reply if it helped to solve your issue, and thumbs-up if you feel this is useful or important in other ways as a boost.

  • eviljoen4 Profile Picture
    21 on at

    Thank you

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 501 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 323 Moderator

#3
abm abm Profile Picture

abm abm 237 Most Valuable Professional

Last 30 days Overall leaderboard