COGNOiSe.com - The IBM Cognos Community

IBM Cognos 8 Platform => COGNOS 8 => Framework Manager => Topic started by: saumil287 on 14 Oct 2011 08:34:50 AM

Title: Unable to union query subject containing dissimilar data types
Post by: saumil287 on 14 Oct 2011 08:34:50 AM
Hi All,
I am having 2 query subjects which has column named BU.
I created the query item for each query subject named BU in framework manager with Data as 'OFR' in one query subject and 'AFR' in another query subject.
1st  query subject other columns data is imported from Excel 2007.
BU column in 1st query subject has Text blob.
BU column in 2nd query subject has charcter length 16 as data type.
2nd query subject other columns data is imported from sqlserver 5
During Union throwing error mismatch data types between Text blob and character length 16.
Is there any way to convert the data type to character length 16 from text blob or vice versa.
need to solve this error.
your guidance will be appreciated
thanks in advance.
Title: Re: Unable to union query subject containing dissimilar data types
Post by: blom0344 on 14 Oct 2011 04:06:16 PM
You need to cast the text blob to a varchar of appropriate length.
Without casting you risk another side effect: Cognos may fetch the primary key of the underlying table ,effectively nullifying any aggregation against data
Title: Re: Unable to union query subject containing dissimilar data types
Post by: saumil287 on 16 Oct 2011 02:03:10 AM
Hi Blom
I used the cat function and I am able to union the query subjects.
Thanks again