Skip to main content

Notifications

Power Automate - Building Flows
Unanswered

Get column display names

Posted on by

@Pstork1 

 

Hello Paul,

 

I've been hoping to hear back from the community on this post for several weeks now so I thought I would try pinging you in hopes you have some advice for me on the question below. I'd be grateful for any help you could offer. Thank you! Teresa

___________________________________________________________________________________________________________________________________

 

A while back Will Page was trying to give me some advice on how to retrieve and display the Title/Display Names of columns rather than the Static/Internal names. Since I'm so new to Power Automate, I'm having trouble following the guidance that can be found in the link below. Since the post was getting long and my original question was around removing properties, I thought I would start a fresh post. 

 

I've gotten as far as retrieving the display names via a "Send an HTTP request to SharePoint" action and putting the results into a Compose action, but I'm having trouble tying the column display names together with the results of whether or not the column has changed. I was wondering if you could help me get across the finish line.

 

Solved: Re: removeProperty Object vs Array Error Message - Power Platform Community (microsoft.com)

 

I'm getting both the StaticName and the Title (display name) back from the Compose step.

Outputs1.png

But the FilterArrayGetChanges step only returns the StaticNames. I'm not clear on what steps and expressions I need to add to the flow steps below. 

 

Outputs2.png

Here are the steps I have so far:

Picture1.pngPicture2.pngPicture3.png

I ran the flow and copied the body of what was returned from the "Send an HTTP..." step into a Compose action.

IPicture4.png

The expression in the right hand field is string(':true')

Picture5.png

Picture7.png

The expression in the right hand field is item()?['StaticName']

Picture8.png

Picture10.png

Part of the And expression got cut off in the screenshot so here is the whole thing.

 

 

 

 

(not(equals(item(),'Modified')),not(equals(item(),'PCFormVersion')), not(equals(item(),'CDWHeadsetURL')), not(equals(item(),'CDWKeyboardURL')))

 

 

 

 

Picture11.pngPicture12.pngPicture13.png

 

 

 

---------
  • pvia Profile Picture
    pvia 2 on at
    Re: Get column display names

    @tagustin were you able to get this figured out? I'm stuck in a similar spot

  • tagustin Profile Picture
    tagustin on at
    Re: Get column display names

    @Pstork1 

     

    Hi Paul,

     

    Thank you for the advice, but I'm afraid I'm too new to Power Apps to figure out how to implement it without you showing me step by step. Here is the Output of my "FilterArrayGetChanges" step. 

     

     FilterArrayChangesOutput.png

    When I attempt to compare the outputs of my 'ComposeTitles' step which has both the static names and titles in it with the 'FilterArrayGetChanges' step I get the following error "The 'from' property value in the 'query' action inputs is of type 'Null'. The value must be an array." I'm pretty sure this is happening because flow isn't able to read it in its current "comparing apples to oranges" formatting issue. I'm not familiar enough with expressions yet to know how to extract the static names where the "has column changed?" value is equal to true and then compare that against the titles/display names that are being returned in the 'ComposeTitles' step which I think is what you are advising to do in Step 1 of your reply. I can't try Step 2 until I get over this hurdle. I'm really new to this so if there is an advanced expression necessary to mine this I would be very grateful for your help.

     

    FilterArrayValues.png

    FilterArrayBody.png

    FilterArrayStaticName.png

    Here is a sample of what the Outputs from my 'ComposeTitles' step looks like.

    {
     "d": {
     "results": [
     {
     "__metadata": {
     "id": "https://fortive.sharepoint.com/sites/TEKCSOEmployees/_api/Web/Lists(guid'e9bae1f6-5440-414f-93c9-f9862ed0e1e2')/Fields(guid'1d22ea11-1e32-424e-89ab-9fedbadb6ce1')",
     "uri": "https://fortive.sharepoint.com/sites/TEKCSOEmployees/_api/Web/Lists(guid'e9bae1f6-5440-414f-93c9-f9862ed0e1e2')/Fields(guid'1d22ea11-1e32-424e-89ab-9fedbadb6ce1')",
     "type": "SP.Field"
     },
     "StaticName": "ID",
     "Title": "ID"
     },

     Thank you, Teresa

  • Pstork1 Profile Picture
    Pstork1 63,884 on at
    Re: Get column display names

    If you have an array with both the internal and display names of the columns then you should be able to use a Lookup() based on the static name you have to find the display name you want.  For example if the static name is "Title" and the displayname is "Fullname" you should be able to do something like this

    1) Filter the ArrayofNames by the staticName

    2) use First(filteredArray).DisplayName to get the DisplayName.

     

     

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

November 2024 Newsletter…

November 2024 Community Newsletter…

Community Update Oct 28…

Power Platform Community Update…

Tuesday Tip #7 Community Profile Tips…

Welcome to a brand new series, Tuesday Tips…

Leaderboard

#1
WarrenBelz Profile Picture

WarrenBelz 143,246

#2
RandyHayes Profile Picture

RandyHayes 76,308

#3
Pstork1 Profile Picture

Pstork1 63,884

Leaderboard