Topic
  • 1 reply
  • Latest Post - ‏2013-10-24T00:34:09Z by mgibson
mgibson
mgibson
215 Posts

Pinned topic Cannot use Substring on TM1 Source...

‏2013-10-23T22:04:07Z |

Hi All,

I have a Month Dimension with a caption like this '2013 - September', but in the charts, I only want it to be displayed as '2013' - because showing the month is a little redundant and takes up room.

A google search has shown that I should be using something like this;

substring(caption([CurrentPeriod]),1,4)

However, when I try and do this, I get this error:

QE-DEF-0459 CCLException

GEN-ERR-0016 the 'substring' function is not supported int he context in which it is used

Is this because the source is a TM1 cube?  Or because [CurrentPeriod] is a calculation (that returns the last member that contains data)?

Does anyone have a suggestion on how I can use the 'Month' Level for a member in the query / chart, but display its parent's name - either by showing the name of the parent (i.e. '2013'), or showing on the first 4 characters of the member caption?

Regards

Mick

  • mgibson
    mgibson
    215 Posts
    ACCEPTED ANSWER

    Re: Cannot use Substring on TM1 Source...

    ‏2013-10-24T00:34:09Z  

    I worked it out myself by setting the 'Source Type' property to 'Report Expression' and putting the Substring expression in there.  This allows the column heading to be altered without affecting the member itself.

    Regards

    Mick

  • mgibson
    mgibson
    215 Posts

    Re: Cannot use Substring on TM1 Source...

    ‏2013-10-24T00:34:09Z  

    I worked it out myself by setting the 'Source Type' property to 'Report Expression' and putting the Substring expression in there.  This allows the column heading to be altered without affecting the member itself.

    Regards

    Mick