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

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Split integers in Powe...
Power Automate
Unanswered

Split integers in Power Automate

(0) ShareShare
ReportReport
Posted on by 4

Hi All,
The selected numbers in Power BI are the input parameter for a function app. I created a measure(selected_value) to store the selected number. For a single selection I used the measure directly in the function app and it worked. But, for multiple input parameters it failed. I tried using split, it didn't work.  
 split(items('Apply_to_each')?[selected_value],',')
Error - The template language function 'split expects its first parameter to be type string. The Provided value is of type integer.
For ex - If the numbers 123 are selected. I need 1,2,3 as input parameters for the function.
If 45 is selected it should be 4,5 as input parameters.

Thankyou

Categories:
  • DamoBird365 Profile Picture
    8,942 Microsoft Employee on at

    Hi @PG45 

     

    If you are looking to convert the string 123 into 1,2,3 from items('Apply_to_each')?[selected_value], you can use the following:

     

    join(chunk(items('Apply_to_each')?[selected_value],1),',')

     

    Chunk splits a string into an array based on a length (in this case 1) and join brings the values back together again with a string, in this case a comma.


    Cheers
    Damien

    Please take a look and subscribe to my YouTube Channel for more Power Platform ideas and concepts. Thanks

  • PG45 Profile Picture
    4 on at

    Thanks, but I want to convert integer 123 into 1,2,3

  • DamoBird365 Profile Picture
    8,942 Microsoft Employee on at

    Hi @PG45 

     

    Then all you will need to add is the expression string https://learn.microsoft.com/en-us/azure/logic-apps/workflow-definition-language-functions-reference#string 

     

    join(chunk(string(items('Apply_to_each')?[selected_value]),1),',')


    Cheers
    Damien

    Please take a look and subscribe to my YouTube Channel for more Power Platform ideas and concepts. Thanks

     

     

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

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Leaderboard > Power Automate

#1
11manish Profile Picture

11manish 321 Super User 2026 Season 2

#2
Mohsin Ali Profile Picture

Mohsin Ali 244

#3
Henil Profile Picture

Henil 102

Last 30 days Overall leaderboard