Cognos Analytics

Cognos Analytics

Connect, learn, and share with thousands of IBM Cognos Analytics users! 

 View Only
Expand all | Collapse all

Block Local Query Processing

  • 1.  Block Local Query Processing

    Posted Wed October 05, 2022 03:08 PM
    Hi all,

    As everybody knows, local processing can degrade severely the environment performance.

    Many functions that users can consume in reports, dashboards and data modules are not push down to database engine.

    Currently, in my case, I have many users that are using date functions in data modules that are based on data sets. And these functions are processing locally, very slow. This because data modules are using flint (spark) serve embed in Cognos.

    I have asked IBM to have a configuration (query service) to limit memory use per report/process and then avoid system issues, but, yet, it is not possible. They guide me to vote an idea.

    So, anyone know if has Cognos a parameter or configuration to block local processing?

    Thanks!

    ------------------------------
    JEAM COELHO
    Cognos Solution Architect

    LinkedIn: https://www.linkedin.com/in/jeamcoelho/
    ------------------------------

    #CognosAnalyticswithWatson


  • 2.  RE: Block Local Query Processing

    Posted Fri October 07, 2022 08:42 AM
    Hi Jeam, Do your Data Modules use Cognos Data Sets (as you wrote in one line) or are they directly based on Data Server Connections (what I would expect if you want the SQL statements to be pushed down to database)? 

    The precise modeling in a Data Module does have a huge impact on if local processing takes place or not. Out of my experience is the complexity and/or the mixture of modeling techniques very relevant (e.g. View from Multiple Tables, Data Module Calculations etc.). Not that much relevant seems to be the business logic complexity of a model. 

    Another aspect with a huge impact is the usage of certain Cognos or vendor specific database functions. I'm not aware of lists of funtions that force local processing for specific data sources. 

    So it might be slight details that require local processing and a closer look could help. Any other input could be helpful for me, too :-)

    ------------------------------
    Philipp Hornung
    ------------------------------



  • 3.  RE: Block Local Query Processing

    Posted Fri October 07, 2022 12:25 PM
    Hi Philipp,

    Thanks for your reply.

    In this case I'm just using datasets with data modules.

    We have more than 1,000 author users and is too hard to force them to user best practices always.

    I wanna block local processing to force using best practices or, in case of issue in CA, report to IBM.

    ------------------------------
    JEAM COELHO
    Cognos Solution Architect

    LinkedIn: https://www.linkedin.com/in/jeamcoelho/
    ------------------------------



  • 4.  RE: Block Local Query Processing

    Posted Fri October 07, 2022 09:18 AM

    If you have a support call open, would help if you reference that in your posts.

    You did not provide any examples of expressions you say are of concern.

    Queries that reference datasets will execute in the Compute Service which supports many of the temporal expressions.



    ------------------------------
    NIGEL CAMPBELL
    ------------------------------



  • 5.  RE: Block Local Query Processing

    Posted Fri October 07, 2022 12:46 PM
    Hi Nigel,

    I have not opened a case because I'm using CA 11.2.1 and I'm not sure if this issue was fixed in CA 11.2.3.

    So, this specific issue with time fields in datasets is simple to reproduce. Look:

    - There are two simple datasets that are joined by Key field.
    - Dataset 1 has two time fields: Start and End date

    - Date Calculation field is: cast( End_Date - Start_Date ; interval second). But same issue occur with _unix_timestamp ( End_Date ) . I need difference between these two timestamps in seconds.


    When adding all those fields to a report, you will see that query is split and join is done by Query Service, not Compute Service.






    ------------------------------
    JEAM COELHO
    Cognos Solution Architect

    LinkedIn: https://www.linkedin.com/in/jeamcoelho/
    ------------------------------



  • 6.  RE: Block Local Query Processing

    Posted Fri October 07, 2022 07:10 PM

    The interval type is not supported with data sets.

    Use _seconds_between ( ) expression instead of type casting to an interval type

    https://www.ibm.com/docs/en/cognos-analytics/11.1.0?topic=administration-queries-uploaded-files-data-sets



    ------------------------------
    NIGEL CAMPBELL
    ------------------------------



  • 7.  RE: Block Local Query Processing

    Posted Sun October 09, 2022 07:21 PM

    Hi Nigel,

    Thanks for your help. Function _seconds_between(  ) works when the two fields are from dataset.

    But, if I try _seconds_between( current_timestamp ; Start_Date ), local processing is done.

    The data module made by an user is doing exactly this, using current_timestamp.

    Is there a way to avoid local processing calculating with current_timestamp?

    Do you know if there is a configuration that can block/deny local processing of queries? We have 1,000 users and we do not have control that is created/developed by them.



    ------------------------------
    JEAM COELHO
    Cognos Solution Architect

    LinkedIn: https://www.linkedin.com/in/jeamcoelho/
    ------------------------------



  • 8.  RE: Block Local Query Processing

    Posted Mon October 10, 2022 03:56 AM
    Hi Jeam, Did you try to use localtimstamp instead of current_timestamp? In some situation this prevents from local processing for reasons unknown to me. Also switching between table associated calculations and data module associated calculations or vice versa, even if it's against the bets. Also switching between calculate before or after aggregation sometimes makes this difference, also sometimes against my intuition. 

    Let me use this ocassion for a call to IBM: I had to deal with many users from multiple companies who easily get to the point that they are convinced that Cognos Analytics is generally slow if one of their reports is slow. Poor performance is absolutely fatal for user (and management) acceptance. Please give us some document or at least a blog post for general guidelines to avoid the most widely spread pitfalls regarding local processing. If we BICC experts get more secure about local processing we can fix and avoid performance problems better and quicker.

    ------------------------------
    Philipp Hornung
    ------------------------------



  • 9.  RE: Block Local Query Processing

    Posted Mon October 10, 2022 10:40 AM
    Hi Philipp,

    Using localtimestamp works without local processing. But this function does not consider my timezone, setting to GMT 00. I'm at GMT -03.
    If I try using another function to set timezone, local processing is used.

    But query macro has worked for me. I have tried _seconds_between( # timestampMask ( $current_timestamp ; 'yyyy-mm-dd hh:mm:ss' ) # ; Start_Date ) and all query was sent to flint service.


    By the way: "I had to deal with many users from multiple companies who easily get to the point that they are convinced that Cognos Analytics is generally slow if one of their reports is slow. Poor performance is absolutely fatal for user (and management) acceptance." is strongly true!


    I'm facing exactly this because of report that is processing locally. Users are complain with all environment because a few poor performance reports.

    ------------------------------
    JEAM COELHO
    Cognos Solution Architect

    LinkedIn: https://www.linkedin.com/in/jeamcoelho/
    ------------------------------



  • 10.  RE: Block Local Query Processing

    Posted Tue October 11, 2022 07:31 AM

    use localtimestamp 



    ------------------------------
    NIGEL CAMPBELL
    ------------------------------



  • 11.  RE: Block Local Query Processing

    Posted Tue October 11, 2022 07:45 AM
    Hi Nigel, OK, but why? How could we have known? And what other things do we need to consider? It would really be a great service by IBM to share more information about local processing. Kind regards, Philipp

    ------------------------------
    Philipp Hornung
    ------------------------------