CRMSalesforce CRM

Salesforce Formula Date and Time Functions

By October 19, 2020No Comments

Salesforce formulas derive their value from other fields, expressions, or values.   They can be used in a number of contexts, including custom fields for auto-calculating values, criteria for data validation and workflow, and Visualforce pages.

Here are the Date Functions available to you whether you are using formula builders in an object or a process or if you are writing the formula in an apex script or visual force page.

Date and Time Functions
DATE Returns a date value from year, month, and day values you enter. Salesforce displays an error on the detail page if the value of the DATE function in a formula field is an invalid date, such as February 29 in a non-leap year.
DATEVALUE Returns a date value from a date/time or text expression.
DAY Returns the day of the month a given date falls on as a number between 1 and 31.
MONTH Returns the month that a given date falls in as a number between 1 (January) and 12 (December).
NOW Returns a date/time value representing the current moment. TODAY Returns the date value of the current date.
YEAR Returns the year that a given date falls in as a number.

5 Great Alternatives to SalesForce.com

Free Whitepaper Download

Learn more about 5 options that are better CRMs for small business

DOWNLOAD WHITEPAPER