IBM Support

What is a tuple?

Technote (troubleshooting)


This document describes what a tuple is and how the tuple function works in query specifications.

Resolving the problem

The tuple function serves to specify the specific context that a filter, sort order or another function (such as value() or rank()) will operate against. A tuple indicates which coordinates of the cube are in use for the operation being executed.

Here are some examples of the tuple function being used...

Within a Query Expression that filters:

Simple use case:

The tuple function serves to specify the specific context that a filter will operate against. In the case of a filter such as ?Top 10 SalesPeople for Q1 of 2012?, the context would likely be the measure (e.g. revenue) and the member 2012 Q1.


TopCount( children of salespeople, 10, tuple([Revenue], [2012 Q1]) )

If a dimension is not represented in the tuple function for a filter, then the default member of each dimension is used for the context.

Within a Query Expression using the Rank function:


rank(<measure> <ordinal direction> TUPLE <member being ranked> WITHIN SET <visible members on opposite axis>)

Simple use case:

User wants to see the rank of each Product Line for the year 2012.

rank(currentMeasure DESC tuple [2012] WITHIN SET [Product Line])

NOTE: In this case, the context used by tuple is not placed in brackets.

Historical Number


Document information

More support for: Cognos Business Intelligence
Report Studio

Software version: 10.2, 10.2.1, 10.2.2

Operating system(s): AIX, HP-UX, Linux, Solaris, Windows

Software edition: All Editions

Reference #: 1339536

Modified date: 03 November 2010

Translate this page: