Forum Discussion

Torbjorn_Andersson's avatar
Torbjorn_Andersson
Copper Contributor
Oct 25, 2021

Update a choice column based on date

Hey!  So I'm trying to automate my SPO List but haven't manage to get it to work. So I was wondering if there is anyone who knows how to do this.   My case: I have a staffing list where I tra...
  • RobElliott's avatar
    Oct 25, 2021

    Torbjorn_Andersson the flow to do this is as follows and in this example we will change Alison Krauss from New Hire to Working as she starts today:

     

    The flow will run once a day at 8am:

     

    We get the items from the list where the Status is 'New Hire'

     

    Format today's date with a Compose and the expression formatDateTime(utcNow(),'yyyy-MM-dd')

    As we've used Get items, add an apply to each and inside it add another Compose control and get the start date then format that with another Compose control and the expression formatDateTime(outputs('ComposeStart'),'yyyy-MM-dd')

    Next, add a condition to check if the output of the ComposeFormatStart is equal to the ComposeToday:

     

     

    If it is, update the Status value to Working:

     

    And this is the result:

     

     

    Rob
    Los Gallardos
    Microsoft Power Automate Community Super User

Resources