The DAYS function returns the number of days in a given time period.

For example, use the DAYS function to find out how many days are in a quarter.

## Syntax

DAYS([Period])

## Arguments

 Argument Data type Description Period (Optional) Time period The period for which to return the number of days.

The DAYS function returns a numeric result.

You can omit the Period argument if the line item you use the DAYS function in is dimensioned by Time. In this case, the DAYS function returns the number of days in each time period of the Time dimension.

If you use the DAYS function in a line item that is not dimensioned by Time, you must provide the Period argument or the function returns an error.

## Examples

### Example with time dimension

 Number of days in month DAYS() Jan 21 31 Feb 21 28 Mar 21 31 Q1 FY21 90 Apr 21 30 May 21 31 Jun 21 30 Q2 FY21 91 H1 FY21 181 Jul 21 31 Aug 21 31 Sep 21 30 Q3 FY21 92 Oct 21 31 Nov 21 30 Dec 21 31 Q4 FY21 92 H2 FY21 184 FY21 365

In this example, the module contains both the Time dimension and a single line item. The line item contains the DAYS function without an argument, so it returns the number of days for each applicable time period of the Time dimension. As the DAYS function returns a numeric result, the Sum summary method aggregates the number of days within each parent time period.

### Example without time dimension

 Product A Launch Product B Launch Month period Feb 19 Feb 20 Quarter period Q1 FY19 Q1 FY20 Year period FY19 FY20 Days in month DAYS(Month period) 28 29 Days in quarter DAYS(Quarter period) 90 91 Days in year DAYS(Year period) 365 366

In this example, the module does not have time as a dimension. As such, the Period argument must be given to use the DAYS function.

A list that describes two different product launches displays on columns. Line items display on rows. The top three line items are time period format. The bottom three line items are number format, and contain formulas to calculate the number of days in the corresponding time periods.

Disclaimer

We update Anapedia regularly to provide the most up-to-date instructions.