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

 

BMT-MD-2047 Cannot assign the "_memberCaption" role to this query item

Started by srinu1253, 01 Jun 2014 06:53:22 PM

Previous topic - Next topic

srinu1253

Hi,

I am getting this error in Cognos Framework Manager. In DMR for Time dimension getting this error for Year.

BMT-MD-2047 Cannot assign the "_memberCaption" role to this query item because its data type is not "string". Either change the query item expression to be of type "string" or create a new string calculated item and assign the role to it.

I tried Casting function Cast([Modelling Layer].[Time].[Year Count],varchar(4)) and to_char function to_char([Modelling Layer].[Time].[Year Count]). But no use.

Any Help would be appreciated.

Francis aka khayman

Year Count is your year? Anyway why don't you cast the Year that you use as business key?

srinu1253


srinu1253

Tried the method which you have saif but Its not working. The Year Count's Datatype in the database is Integer.I am trying to create a DMR having Year in the top most hierarchy(with business key and member Caption).But I am getting the above error.

Francis aka khayman

you are getting the above error because your Year is an integer and caption needs a string. convert the integer into a string and the above error will disappear.

now, you said you tried to cast to string "but no use". what does that mean? does it mean you cast to string but there is still an error (unlikely), or you were not able to cast? if so what is the error?

bus_pass_man

Yeah more detail about the observed behaviour would be useful.   When you test the expression, what do you see?   

What is the size of the year count column?   It's possible that you ought to try to increase the size of the varchar.   When you specify the varchar size as 4 you're saying that the largest value in your column is 4 digits.   Sometimes when I've specified too small a size I get results like blanks and truncated values.

MFGF

Can you be specific about what exact item you are using for your ID and your caption? You refer to both Year and Year Count. Are you casting one and using the other? Where are you doing the casting - in an expression in the regular dimension or elsewhere?

MF.
Meep!