newNegativeAttributeFilter()
Home > @gooddata/sdk-model > newNegativeAttributeFilter
newNegativeAttributeFilter() function
Creates a new negative attribute filter.
Signature:
export declare function newNegativeAttributeFilter(attributeOrRef: IAttribute | ObjRef | Identifier, notInValues: IAttributeElements | string[], localIdentifier?: string): INegativeAttributeFilter;
Parameters
Parameter | Type | Description |
---|---|---|
attributeOrRef | IAttribute | ObjRef | Identifier | either instance of attribute to create filter for or ref or identifier of attribute's display form |
notInValues | IAttributeElements | string[] | values to filter out; these can be either specified as AttributeElements object or as an array of attribute element _values_; if you specify empty array, then the filter will be noop and will be ignored |
localIdentifier | string | (Optional) |
Returns:
Remarks
NOTE: when specifying attribute element using URIs (primary keys), please keep in mind that they MAY NOT be transferable across workspaces. On some backends same element WILL have different URI in each workspace. In general we recommend using URIs only if your code retrieves them at runtime from backend using elements query or from the data view's headers. Hardcoding URIs is never a good idea, if you find yourself doing that, please consider specifying attribute elements by value