COGNOiSe.com - The IBM Cognos Community

Legacy Business Intelligence => COGNOS ReportNet => Topic started by: pali on 30 Apr 2006 06:22:57 AM

Title: use of Function in report
Post by: pali on 30 Apr 2006 06:22:57 AM
hi
I have created a function in DB2 database that has 4 input parameter and that returns a integer.
After that i have imported that in my model using framework manager and then published it.
When i am using it in report it works fines as calulation. But when i am trying to get summeries it gives me a error that
QuoteQE-DEF-0177 An error occurred while performing operation 'sqlPrepareWithOptions' status='-9'. UDA-SQL-0107 A general exception has occurred during the operation "prepare". [IBM][CLI Driver][DB2/AIX64] SQL0583NÃ,  The use of routine "FGETCNT_LOC" is invalid because it is not deterministic or has an external action.Ã,  SQLSTATE=42845Ã, 
RSV-RND-0052 Failed to validate the layout due to missing metadata information for query 'Query1'.
and while performing calulation based on that only in division operator it gives me same error.
Is there any way to achieve so.

Any kind of suggestion will be also helpful.
Title: Re: use of Function in report
Post by: bdybldr on 03 May 2006 08:13:58 AM
I've read that DB2 doesn't support "sort" or "order by" on a column with more than 255 characters.  If your query in ReportStudio is using "select distinct", DB2 applies "order by". 

To fix this, turn off "Auto Group and Summarize" in ReportStudio" for that tabular model.

HTH.  Keep us posted.