Tm1 REST api - search dimension elements by Attributes Alias

Post Reply
kavitha2002
Community Contributor
Posts: 180
Joined: Sat May 05, 2018 11:48 am
OLAP Product: tm1
Version: 10.3.10100.8
Excel Version: 14

Tm1 REST api - search dimension elements by Attributes Alias

Post by kavitha2002 »

Hi Everyone,

Is there any search/filter option available in Tm1 REST api? I would like to search the elements in Dimension as search string "G0*" with respect to alias L01 or L02.

I have found the below,

Code: Select all

http://host:8001/api/v1/Dimensions('DimName')/Hierarchies('DimName')/Members('Liabilities') 
-- It gives the elements based on the matching alias. But I have to search as '*iab*' so that all matching alias elements should come in response. Any idea?


Thanks.
kavitha2002
Community Contributor
Posts: 180
Joined: Sat May 05, 2018 11:48 am
OLAP Product: tm1
Version: 10.3.10100.8
Excel Version: 14

Re: Tm1 REST api - search dimension elements by Attributes Alias

Post by kavitha2002 »

Code: Select all

http://host:8001/api/v1/Dimensions('DimName')/Hierarchies('DimName')?$expand=Elements($select=Attributes)
The above query result to below array of elements, but I would like to filter the Attributes.L03 .. Is it possible??

"Elements": [
{
"@odata.id": "Dimensions('DimName')/Hierarchies('DimName')
Elements('A00000')",
"@odata.etag": "W/"1167619dim7429elemAttributes15081"",
"Attributes": {
"Caption": "A00000",
"Bereich": "A",
"BuTabelle": "bg",
"BuSperre": "C",
"L04": "Assets",
"L03": "Assets",
"Format": "#,##0.00",
"Soll/Haben": "S",
"Wechselkurs": "E01"
}
},
kunbela
Posts: 5
Joined: Thu Feb 22, 2018 4:19 pm
OLAP Product: TM1
Version: 10.2.2
Excel Version: 2016

Re: Tm1 REST api - search dimension elements by Attributes Alias

Post by kunbela »

This answer might be a bit late, but might good for the future Google searches:

Try the following way:

Code: Select all

http://host:8001/api/v1/Dimensions('DimName')/Hierarchies('DimName')/Elements?$filter=Attributes/Bereich eq 'A'
(Filtering fotr Bereich attribute equal to A.)
Post Reply