Skip to main content

Notifications

Power Platform Community / Forums / Building Flows / Select an object entry...
Building Flows
Answered

Select an object entry according to a variable value

Posted on by 30
Hi there,
 
I want to select a column from a object dropped from a teams list. the column name depend on the current date.
 
The flow is triggered every sunday at 11:00 pm.
 
From current date I get the week number, and I create a variable with the column name I want to select in the 
 
I want to use this variable to select the column I want in my object, to then get the data from this column
 
Is there a way to perform such a dynamic column selection?
 
thanks!
 
  • Verified answer
    SP-04091518-0 Profile Picture
    SP-04091518-0 30 on at
    Select an object entry according to a variable value
    I create an array "dynamicFields' with all the possible fields ['week1', 'week2', ..., 'week42']
     
    I set up the current week number in the variable "reportNumber"
     
    then I used the select action:
    • my object as input
    • map is set up with a function: 
    item()?[variables('dynamicFields')[variables('reportNumber')]]
     
  • SP-04091518-0 Profile Picture
    SP-04091518-0 30 on at
    Select an object entry according to a variable value
    all right, this is my flow:
     
    here is a sample of what comes out of the "get item" action. I have 24 entries and I want to select one of them
     
  • Suggested answer
    FLMike Profile Picture
    FLMike 23,258 on at
    Select an object entry according to a variable value
    Hi,
     
    Please provide actual examples with visuals. just sorta tossing out details is not enough and too much to ask of people.
     
    Make it super simple for us to answer by providing step by step, with actual details so we can help you 1 time :-) and get you sorted.

Helpful resources

Quick Links

Welcome to the Power Platform…

We are thrilled to unveil the newly-launched Power Platform Communities!…

Community Update Sept 16…

Power Platform Community Update…

Welcome to the new Power Platform Community!…

We are excited to announce our new Copilot Cookbook Gallery in the Community…

Leaderboard

#1
WarrenBelz Profile Picture

WarrenBelz 140,719

#2
RandyHayes Profile Picture

RandyHayes 76,308

#3
Pstork1 Profile Picture

Pstork1 63,355

Leaderboard

Featured topics