newRelativeDateFilter()
Home > @gooddata/sdk-model > newRelativeDateFilter
newRelativeDateFilter() function
Creates a new relative date filter.
Signature:
export declare function newRelativeDateFilter(dateDataSet: ObjRef | Identifier, granularity: DateAttributeGranularity, from: number, to: number): IRelativeDateFilter;
Parameters
Parameter | Type | Description |
---|---|---|
dateDataSet | ObjRef | Identifier | ref or identifier of the date data set to filter on |
granularity | DateAttributeGranularity | granularity of the filters (month, year, etc.) |
from | number | start of the interval – negative numbers mean the past, zero means today, positive numbers mean the future |
to | number | end of the interval – negative numbers mean the past, zero means today, positive numbers mean the future See also DateAttributeGranularity and DateGranularity |
Returns: