What's new Download Reportworq
⬇ Guide PDF

TM1SET function#

TM1SET is the hierarchy-aware equivalent of SUBNM and DIMNM, with additional output modes. It defines an MDX set for a dimension hierarchy and returns the selected member, its unique name, or the session set id.

TM1SET is a native TM1 / Planning Analytics function.

Signature#

=TM1SET(host, server, dimension, hierarchy, setExpression, [selectedElement], [sessionSetOut], [activeDisplay], [displayMode])

Arguments#

# Argument Type Required Permitted values and notes
1 host String Yes The host environment. Ignored by Reportworq, but must be non-blank and not an Excel error value.
2 server String Yes The server instance.
3 dimension String Yes The dimension. A non-existent dimension is a hard error.
4 hierarchy String Yes The hierarchy. A non-existent hierarchy is a hard error.
5 setExpression String Yes The MDX set expression.
6 selectedElement String No The member to return. Blank returns the first set member; a member not in the set returns the first member. Case- and space-sensitive.
7 sessionSetOut Range No An output cell for the session set id. Referencing more than one cell is a hard error. See the limitation below.
8 activeDisplay String No An alias attribute to display when displayMode is MEMBERDISPLAY.
9 displayMode String No MEMBERDISPLAY (default), MUN, or SESSIONSET. An unrecognized value falls back to MEMBERDISPLAY.

TM1SET takes five to nine arguments.

What happens when an argument is wrong#

Situation Result
Fewer than five arguments Hard error - too few parameters
More than nine arguments Hard error - too many parameters
Blank host, server, dimension, hierarchy, or setExpression Hard error
A non-existent dimension or hierarchy Hard error
sessionSetOut references more than one cell Hard error - the cell shows #VALUE!

Notes and limits#

Examples#

=TM1SET("*", "PlanTM1", "Region", "Region", "{[Region].[Region].Members}", "Northeast", , , "MEMBERDISPLAY")

Feedback on this page

Comments, questions, requests, or something missing or unclear? Email us - the page you are on is filled in for you.

Email feedback on this page

Or write to support@reportworq.com directly.