Forum Discussion

ak264's avatar
ak264
Copper Contributor
Sep 26, 2023

Get Date Modified of individual columns

I have a list with a number of Choice columns, lets call them Column A, Column B & Column C.  I need to have a corresponding collumn for each of these with Date Modified (e.g. Col. A Modified, Col B. Modified, Col C. Modified). 

 

I have tried Calculated columns and Power Automate but cant find a solution that works.  Any suggestions greatly appreciated!

  • LeonPavesic's avatar
    LeonPavesic
    Silver Contributor

    Hi ak264,

    there is no way to get the date modified of individual columns in SharePoint out of the box.

    However, there are a couple of workarounds you can use:

    Calculated columns

    You can use a calculated column to get the date modified of a specific column, but it requires you to compare the value in the column with the value in the previous version. If the column values don't match, then the modified date for the row is the modified date for that column.

    To do this:

    - Go to the list where you want to add the calculated column.
    - Click Settings > List settings.
    - Under Columns, click Create column.
    - Select Calculated and click Next.
    - In the Column name field, enter a name for the calculated column, such as Column A Modified.
    - In the Column type field, select Date and time.
    - In the Formula field, enter the following formula:

    =IF([Column A]=[Column A_PreviousVersion],"",[Modified])


    Click OK to save the calculated column.

    Power Automate

    You can also use Power Automate to create a flow that will update a new column with the date modified of a specific column. To do this:

    - Go to Power Automate.
    - Click Create > Flow.
    - Select Automated from blank.
    - In the When an item is modified trigger, select the list where you want to track the date modified of the Choice columns.
    - Click Add new action.
    - Search for and select the Get item action.
    - In the Site Address field, enter the URL of your SharePoint site.
    - In the List Name field, select the list where you want to track the date modified of the Choice columns.
    - In the Item ID field, enter the dynamic content for the ID of the modified item.
    - Click Add new action.
    - Search for and select the Update item action.
    - In the Site Address field, enter the URL of your SharePoint site.
    - In the List Name field, select the list where you want to track the date modified of the Choice columns.
    - In the Item ID field, enter the dynamic content for the ID of the modified item.
    - In the Field field, select the new column that you want to update with the date modified of the Choice column.
    - In the Value field, enter the following expression:

    {{triggerBody()?['Modified']}}


    - Click Save.

    Once you have created the calculated columns or Power Automate flows, you should be able to see the date modified of each Choice column in your list.

    https://powerusers.microsoft.com/t5/Building-Power-Apps/How-to-retrieve-the-timestamp-of-a-specific-columns-last/td-p/2135250

    Please click Mark as Best Response & Like if my post helped you to solve your issue.
    This will help others to find the correct solution easily. It also closes the item.


    If the post was useful in other ways, please consider giving it Like.


    Kindest regards,


    Leon Pavesic
    (LinkedIn)

    • Chairat_Jin's avatar
      Chairat_Jin
      Copper Contributor

      LeonPavesic  Thank you so much Sir... you help me to fix the problem for long time... Thank you so much 

      • LeonPavesic's avatar
        LeonPavesic
        Silver Contributor

        Hi Chairat_Jin,

        thanks for the update.

        You are welcome.



        Please click Mark as Best Response & Like if my post helped you to solve your issue.
        This will help others to find the correct solution easily. It also closes the item.


        If the post was useful in other ways, please consider giving it Like.


        Kindest regards,


        Leon Pavesic
        (LinkedIn)
        (Twitter)

    • ak264's avatar
      ak264
      Copper Contributor

      Hi LeonPavesic

      Thanks for your help!

      The Calculated column would be the best way for us, unfortuantly when using the Formular, I am gettting this error message "The formula refers to a column that does not exist. Check the formula for spelling mistakes or change the non-existing column to an existing column.".

       

      I have double checked the names are correct so I believe the column which doesnt exist is the Column A_PreviousVersion. Do I need to do anything specific to get the Column A_PreviousVersion column active? Thanks

Resources