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 / initialize variables z...
Power Automate
Answered

initialize variables zip code and city with bing map get location by point

(0) ShareShare
ReportReport
Posted on by 230

Hi everyone!

in my CDS I have GPS point and I would like to create a flow that fill the zip code and the city in the same CDS.

How could I split zip code and city from the result of a "get location by point"?

kind regards

Categories:
I have the same question (0)
  • Gristy Profile Picture
    2,429 on at

    There is a variable that is returned for Postal Code. 

     

    You will need to do string manipulation for the City though.

     

    Here is a quick reference: https://faustocapellan.com/2018/05/01/express-yourself-string-functions-in-microsoft-flow/

  • v-bacao-msft Profile Picture
    on at

     

    Hi @Kesh ,

     

    Please try this configuration to get zip code and city name:

    123.PNG

    Expression reference:

    trim(split(body('Get_location_by_point')?['name'],',')[1])

    Hope it helps.

     

    Best Regards,

  • Kesh Profile Picture
    230 on at

    hi @v-bacao-msft,

    thank you for your answer,

    I still have the zip code in the var, How could I remove it?

    kind regards

  • v-bacao-msft Profile Picture
    on at

     

    Hi @Kesh ,

     

    Please give an example of what values you need.

     

    Regards,

  • Kesh Profile Picture
    230 on at

    for example, for the latitude : 48.85837 and longitude :2.294481 (eiffel tower)

    the result of your expression is "75007 Paris" and I don't need the "75007 ". How could I remove that?

    kind regards.





  • Verified answer
    v-bacao-msft Profile Picture
    on at

     

    Try this expression:

    trim(replace(trim(split(body('Get_location_by_point')?['name'],',')[1]),body('Get_location_by_point')?['address']?['postalCode'],''))

    Regards,

  • Kesh Profile Picture
    230 on at

    Thank you it works!!

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