If you are unable to create a new account, please email support@bspsoftware.com

 

News:

MetaManager - Administrative Tools for IBM Cognos
Pricing starting at $2,100
Download Now    Learn More

Main Menu

Trim Value

Started by Jkelly228, 17 Jun 2011 05:53:51 PM

Previous topic - Next topic

Jkelly228

Hello All,

I have a value where I need to trim the first 19 characters off in order make it more usable. I am graphing some data and it all starts off "Hold:1 = Line:Sales Real Value" (substitute "Real Value" for the true reason for the hold). I need to get rid of the portion in red in order to get a true value for the chart.

Below is the what I have so far for trim, but I just get an error back. I am sure it is simple, but I am pretty new to this. Thank you in advance.

trim(leading,[OracleCustomObjects].[HYP_DW_BOOK_OPEN_SHIP].[HOLD_REASONS],15)

Kelly

cognostechie

Why not just use the substring function? and in your case, you have to trim 20 characters, not 19 otherwise you will be displaying a blank before the 'Real Value'.

substring([OracleCustomObjects].[HYP_DW_BOOK_OPEN_SHIP].[HOLD_REASONS],20,50)

Replace 50 with the no. of characters you want to be displayed and replace [OracleCustomObjects].[HYP_DW_BOOK_OPEN_SHIP].[HOLD_REASONS] with whatever name you have in Cognos.

Jkelly228

Thank you. this worked perfectly. I appreciate you taking the time to explain it to me as well. I have a lot of uses for it.

Kelly