Activity › Forums › Salesforce® Discussions › How can I know the Day of the Week of a Date in Salesforce? Tagged: Date Field, Datetime Field, Salesforce Apex, Salesforce Formula Field, Salesforce formulas, Salesforce Visualforce, SOQL Salesforce® Discussions How can I know the Day of the Week of a Date in Salesforce? Posted by Ravi on April 30, 2016 at 6:12 PM How can I know the Day of the Week of a Date? Avnish Yadav replied 7 years, 7 months ago 3 Members · 2 Replies Date FieldDatetime FieldSalesforce ApexSalesforce Formula FieldSalesforce formulasSalesforce VisualforceSOQL 2 Replies Surbhi Member May 31, 2016 at 6:03 AM Hi Ravi, In SOQL, use the “DAY_IN_WEEK()“. It returns a number representing the day of the week for a date field. In formula field, you can use this: CASE( MOD( Date_Field – DATE(1900, 1, 7), 7), 0, “Sunday”, 1, “Monday”, 2, “Tuesday”, 3, “Wednesday”, 4, “Thursday”, 5, “Friday”, 6, “Saturday”,”Error”) Thanks [adinserter block='9'] Avnish Yadav Member September 29, 2018 at 8:29 PM Try this: CASE( MOD( Date__c – DATE(1900, 1, 7), 7), 0, “Sunday”, 1, “Monday”, 2, “Tuesday”, 3, “Wednesday”, 4, “Thursday”, 5, “Friday”, 6, “Saturday”,”Error”) Log In to reply. Public All Members My Connections Only Me PublicAll MembersMy ConnectionsOnly Me Public All Members My Connections Only Me