web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Fill the year week day...
Power Automate
Suggested Answer

Fill the year week day in a sharepoint column

(0) ShareShare
ReportReport
Posted on by 4
Good morning,
 
In sharepoint I have a list with several columns, one of them is a date field. I would like to, in another column, say "Weekday" get the year weekday for that date. I have tried several ways, but can't get it. Do you know a formula that can do it? or any other way? I have even tried to create a list with all the dates of the year and its weekdays and compare the date on the triggerbody "when an item is created or modified" and then compare it with the date in the list but it never finds a likeness
 
I'm relly out of ideas.
 
Can anyone help me?
I have the same question (0)
  • Nived_Nambiar Profile Picture
    18,138 Super User 2026 Season 1 on at
    did you meant by year weekday by whether it is Monday, Tuesday etc for given date?
     
    May be i am bit confused ?
     
     
     
  • RS-18101147-0 Profile Picture
    4 on at
    Hi, sorry if I didn't explain myself, I have a column in a sharepoint list and I need to have another column with the weekyear of that date, I mean, for example, for the date 10/11/2024 (spanish date form dd/mm/yyyy) I want to obtain in a column like "weekday" the value 46, wich is the weekyear number for that date.
     
    Can anyone help me? I have tried all this formulas in a calculated column, but they don't work:
     
    =INT((TODAY()-DATE(YEAR(TODAY());1;1)+(TEXTO(WEEKDAY(DATE(YEAR(TODAY());1;1));"d")))/7)-INT((Fecha-DATE(YEAR(Fecha);1;1)+(TEXTO(WEEKDAY(DATE(YEAR(Fecha);1;1));"d")))/7)
    =INT(([Fecha] - DATE(YEAR([Fecha]); 1; 1) + WEEKDAY(DATE(YEAR([Fecha]); 1; 1); 2)) / 7) + 1
    =INT(([Fecha] - DATE(YEAR([Fecha]); 1; 1) - WEEKDAY(DATE(YEAR([Fecha]); 1; 1) - 1) + 7) / 7)
    =INT(( [Fecha] - DATE(YEAR([Fecha]); 1; 1) - WEEKDAY(DATE(YEAR([Fecha]); 1; 1) - 1) + 11) / 7)
    =INT(([Fecha]-DATE(YEAR([Fecha]),1,1)+(weekdayDate(YEAR([Fecha]),1,1)),"d")))/7)
    =INT(([Fecha]-DATE(YEAR([Fecha]);1;1)+(TEXT(WEEKDAY(DATE(YEAR([Fecha]);1,1));"d")))/7)
    =CONCATENATE(TEXT(IF(INT(([Fecha]-DATE(YEAR([Fecha]),1,1)+(TEXT(WEEKDAY(DATE(YEAR([Fecha]),1,1)-1),"d")))/7)=0,52,INT(([Fecha]-DATE(YEAR([Fecha]),1,1)+(TEXT(WEEKDAY(DATE(YEAR([Fecha]),1,1)-1),"d")))/7)),"0"))
     
    I have also tried a power automate flow using another list  with all the dates of 2024 and besides its weeknumber, but when I try a for each loop it becomes ethernal or simply doesn't work
     
    Thanks a lot
  • Suggested answer
    Nived_Nambiar Profile Picture
    18,138 Super User 2026 Season 1 on at
    Hi,
     
    well i found a way to do this, used a mathematical formula to acheive this !
     
    see below
     
     
    Here i am passing the date in a variable - date1, and next i am using a compose action to write the expression to get the weeknumber.
     
    Expression used is
    div(add(dayOfYear(variables('date1')),add(mul(add(dayOfWeek(concat(formatDateTime(utcNow(),'yyyy'),'-01-01')),1),-1),10)),7)
     
     
    See whether this can help u !
     
    Mark it as solution if it resolves your query !
     
    Thanks & Regards,
    Nived N
     

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

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Congratulations to the March Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Automate

#1
Haque Profile Picture

Haque 552

#2
Valantis Profile Picture

Valantis 388

#3
11manish Profile Picture

11manish 375

Last 30 days Overall leaderboard