Quantcast
Channel: SCN: Message List
Viewing all articles
Browse latest Browse all 3585

Re: HANA Parameters to restrict Memory Usage

$
0
0

Hi Martin,

 

Thank you for the Hint. As you suggested, I tried to figure out the top consumers list according to the SQL statements Zip file available in OSS note: 1969700. In this Zip file, I referred the "HANA_Memory_TopConsumers" text file and tried to execute the following code in HANA studio:

 

*/

 

  HOST,

  LPAD(PORT, 5) PORT,

  AREA,

  DETAIL,

  SIZE_GB,

  SIZE_PCT,

  ***_SIZE_PCT,

  DESCRIPTION,

  MEMORY_REDUCTION_APPROACHES

FROM

( SELECT

    CASE WHEN AGGREGATE_BY = 'NONE' OR INSTR(AGGREGATE_BY, 'HOST')   != 0 THEN HOST          ELSE MAP(BI_HOST, '%', 'any', BI_HOST) END HOST,

    CASE WHEN AGGREGATE_BY = 'NONE' OR INSTR(AGGREGATE_BY, 'PORT')   != 0 THEN TO_CHAR(PORT) ELSE MAP(BI_PORT, '%', 'any', BI_PORT) END PORT,

    CASE WHEN AGGREGATE_BY = 'NONE' OR INSTR(AGGREGATE_BY, 'AREA')   != 0 THEN AREA          ELSE MAP(BI_AREA, '%', 'any', BI_AREA) END AREA,

    CASE WHEN AGGREGATE_BY = 'NONE' OR INSTR(AGGREGATE_BY, 'DETAIL') != 0 THEN DETAIL        ELSE 'any'                             END DETAIL,

    LPAD(TO_DECIMAL(SUM(SIZE_BYTE) / 1024 / 1024 / 1024, 12, 2), 10) SIZE_GB,

    LPAD(TO_DECIMAL(SUM(SIZE_BYTE) / TOTAL_USED_BYTE * 100, 5, 2) , 8) SIZE_PCT,

    SUM(SIZE_BYTE) / TOTAL_USED_BYTE * 100 SIZE_PCT_ORIG,

    ROW_NUMBER () OVER (ORDER BY SUM(SIZE_BYTE) DESC) ROW_NUM,

    LPAD(TO_DECIMAL(SUM(SUM(SIZE_BYTE) / TOTAL_USED_BYTE * 100) OVER (ORDER BY SUM(SIZE_BYTE) DESC), 5, 2), 12) ***_SIZE_PCT,

    CASE WHEN AGGREGATE_BY = 'NONE' OR INSTR(AGGREGATE_BY, 'DETAIL') != 0 THEN MAX(DESCRIPTION)                 ELSE 'various' END DESCRIPTION,

    CASE WHEN AGGREGATE_BY = 'NONE' OR INSTR(AGGREGATE_BY, 'DETAIL') != 0 THEN MAX(MEMORY_REDUCTION_APPROACHES) ELSE 'various' END MEMORY_REDUCTION_APPROACHES,

    RESULT_ROWS,

    AGGREGATE_BY,

    MIN_SIZE_PCT

  FROM

  ( SELECT

      D.HOST,

      D.PORT,

      ( SELECT SUM(TOTAL_MEMORY_USED_SIZE) FROM M_SERVICE_MEMORY SM

        WHERE SM.HOST LIKE BI.HOST AND TO_CHAR(SM.PORT) LIKE BI.PORT ) TOTAL_USED_BYTE,

      D.AREA,

      D.DETAIL,

      D.SIZE_BYTE,

      D.DESCRIPTION,

      D.MEMORY_REDUCTION_APPROACHES,

      BI.RESULT_ROWS,

      BI.AGGREGATE_BY,

      BI.MIN_SIZE_PCT,

      BI.HOST BI_HOST,

      BI.PORT BI_PORT,

      BI.AREA BI_AREA

    FROM

    ( SELECT                                          /* Modification section */

        '%' HOST,

        '%' PORT,

        '%' AREA,                                  /* ROW, COLUMN, HEAP, CODE, STACK */

        20 RESULT_ROWS,

        -1 MIN_SIZE_PCT,

        'NONE' AGGREGATE_BY,                          /* HOST, PORT, AREA, DETAIL or comma separated combinations, NONE for no aggregation */

        ' ' INCLUDE_OVERLAPPING_HEAP_AREAS            /* Consider heap areas like Pool/malloc/libhdbbasement.so although they overlap with table information */

      FROM

        DUMMY

    ) BI,

    ( SELECT

        HOST,

        PORT,

        'Heap area' AREA,

        CATEGORY DETAIL,

        EXCLUSIVE_SIZE_IN_USE SIZE_BYTE,

        IFNULL(HA.DESCRIPTION, '') DESCRIPTION,

        IFNULL(HA.RECOMMENDATION, '') MEMORY_REDUCTION_APPROACHES

      FROM

        M_HEAP_MEMORY H LEFT OUTER JOIN

      ( SELECT 'AllocateOnlyAllocator-unlimited/FLA-UL<3145728,1>/MemoryMapLevel2Blocks' ALLOCATOR, 'Internal memory management' DESCRIPTION, 'Open SAP incident in case of very large and rising size' RECOMMENDATION FROM DUMMY UNION ALL

        SELECT 'Pool/AttributeEngine',                               'Column store',                                           'Cleanup, compression and archiving of column store tables' FROM DUMMY UNION ALL

        SELECT 'Pool/AttributeEngine/idattribute',                   'Column store',                                           'Cleanup, compression and archiving of column store tables' FROM DUMMY UNION ALL

        SELECT 'Pool/AttributeEngine-IndexVector%',                  'Column store',                                           'Cleanup, compression and archiving of column store tables' FROM DUMMY UNION ALL

        SELECT 'Pool/AttributeEngine/Delta%',                        'Column store',                                           'Reduce delta storages (SAP Note 2057046)'                  FROM DUMMY UNION ALL

        SELECT 'Pool/BitVector',                                     'Basic data structure (incl. MVCC in column store)',      'Avoid long running (update) transactions'                  FROM DUMMY UNION ALL

        SELECT 'Pool/CS_TableSearch',                                'Query optimizer related data structure',                 'Reduce processed SQL data, avoid "SELECT *"'               FROM DUMMY UNION ALL

        SELECT 'Pool/DocidValueArray',                               'Join related rowid / value set',                         'Reduce processed join SQL data, avoid "SELECT *"'          FROM DUMMY UNION ALL

        SELECT 'Pool/itab%',                                         'Intermediate query results',                             'Reduce processed SQL data, avoid "SELECT *"'               FROM DUMMY UNION ALL

        SELECT 'Pool/JoinEvaluator/JECreateNTuple',                  'Join tuples',                                            'Reduce processed SQL data, avoid "SELECT *"'               FROM DUMMY UNION ALL

        SELECT 'Pool/JoinEvaluator/JERequestedAttributes/Results',   'Join results',                                           'Reduce processed SQL data, avoid "SELECT *"'               FROM DUMMY UNION ALL

        SELECT 'Pool/JoinEvaluator/NTuple',                          'Join tuples',                                            'Reduce processed SQL data, avoid "SELECT *"'               FROM DUMMY UNION ALL

        SELECT 'Pool/JoinEvaluator/TranslationTable',                'Join column mapping',                                    'See SAP Note 1998599'                                      FROM DUMMY UNION ALL

        SELECT 'Pool/LVCAllocator%',                                 'liveCache data',                                         'liveCache data management'                                 FROM DUMMY UNION ALL

        SELECT 'Pool/malloc/libhdbcs%',                              'Column store',                                           'Cleanup, compression and archiving of column store tables' FROM DUMMY UNION ALL

        SELECT 'Pool/malloc/libhdbrskernel.so',                      'Row store components',                                   'Open SAP incident in case of very large and rising size'   FROM DUMMY UNION ALL

        SELECT 'Pool/mdx',                                           'MDX query allocations',                                  'Implement SPS 09 or higher'                                FROM DUMMY UNION ALL

        SELECT 'Pool/parallel%',                                     'OLAP aggregation results',                               'Reduce processed SQL data, avoid "SELECT *"'               FROM DUMMY UNION ALL

        SELECT 'Pool/PersistenceManager/ContainerFileIDMapping',     'LOB container mapping',                                  'Large in case of many LOBs, improved with Rev. 94'         FROM DUMMY UNION ALL

        SELECT 'Pool/PersistenceManager/PersistentSpace(0)/DefaultLPA/Page', 'Page cache',                                     'Space is automatically reclaimed if required'              FROM DUMMY UNION ALL

        SELECT 'Pool/PersistenceManager/PersistentSpace(0)/StaticLPA/Page', 'liveCache page cache',                            'liveCache data management'                                 FROM DUMMY UNION ALL

        SELECT 'Pool/RowEngine/CpbTree',                             'Row store indexes',                                      'Avoid unnecessary large row store indexes'                 FROM DUMMY UNION ALL

        SELECT 'Pool/RowEngine/MonitorView',                         'Monitoring view information',                            'See SAP Note 2112732 (SPS 08 and below)'                   FROM DUMMY UNION ALL

        SELECT 'Pool/RowEngine/QueryExecution',                      'Row engine results',                                     'Reduce processed SQL data, avoid "SELECT *"'               FROM DUMMY UNION ALL

        SELECT 'Pool/RowEngine/Session',                             'Session management',                                     'Reduce connections and processed SQL data'                 FROM DUMMY UNION ALL

        SELECT 'Pool/RowEngine/SQLPlan',                             'SQL cache',                                              'See SAP Note 2124112'                                      FROM DUMMY UNION ALL

        SELECT 'Pool/RowEngine/Version',                             'Row store version management',                           'Avoid long running (update) transactions'                  FROM DUMMY UNION ALL

        SELECT 'Pool/Statistics',                                    'Internal statistical information',                       'Open SAP incident in case of very large and rising size'   FROM DUMMY UNION ALL

        SELECT 'Pool/StatisticsServer%',                             'Standalone statistics server data',                      'See SAP Note 1917938 and migrate to embedded stat. server' FROM DUMMY UNION ALL

        SELECT 'Pool/UdivListMgr/UdivListContainer',                 'Column store version management',                        'Avoid long running (update) transactions'                  FROM DUMMY UNION ALL

        SELECT 'Pool/ValueArray',                                    'Join results',                                           'Reduce processed SQL data, avoid "SELECT *"'               FROM DUMMY

      ) HA ON

          H.CATEGORY LIKE HA.ALLOCATOR

      UNION ALL

      ( SELECT

          HOST,

          PORT,

          'Stack' AREA,

          'Stack' DETAIL,

          STACK_SIZE SIZE_BYTE,

          'Space allocated for stack' DESCRIPTION,

          ' ' MEMORY_REDUCTION_APPROACHES

        FROM

          M_SERVICE_MEMORY

      )

      UNION ALL

      ( SELECT

          HOST,

          PORT,

          'Row store',

          'Row store fragmentation',

          SUM(FREE_SIZE),

          'Row store fragmentation',

          'See SAP Note 1813245 and reorganize row store'

        FROM

          M_RS_MEMORY

        GROUP BY

          HOST,

          PORT

      )

      UNION ALL

      ( SELECT

          HOST,

          PORT,

          AREA,

          TABLE_NAME DETAIL,

          SIZE_BYTE,

          'Size of table ' || TABLE_NAME || ' in ' || LOWER(AREA) DESCRIPTION,

          CASE WHEN TABLE_NAME IN

          ( 'BALHDR', 'BALHDRP', 'BALM', 'BALMP', 'BALDAT', 'BALC',

            'BAL_INDX', 'EDIDS', 'EDIDC', 'EDIDOC', 'EDI30C', 'EDI40', 'EDID4',

            'IDOCREL', 'SRRELROLES', 'SWFGPROLEINST', 'SWP_HEADER', 'SWP_NODEWI', 'SWPNODE',

            'SWPNODELOG', 'SWPSTEPLOG', 'SWW_CONT', 'SWW_CONTOB', 'SWW_WI2OBJ', 'SWWCNTP0',

            'SWWCNTPADD', 'SWWEI', 'SWWLOGHIST', 'SWWLOGPARA', 'SWWWIDEADL', 'SWWWIHEAD',

            'SWWWIRET', 'SWZAI', 'SWZAIENTRY', 'SWZAIRET', 'SWWUSERWI',                

            'BDCP', 'BDCPS', 'BDCP2', 'DBTABLOG', 'DBTABPRT',

            'ARFCSSTATE', 'ARFCSDATA', 'ARFCRSTATE', 'TRFCQDATA',

            'TRFCQIN', 'TRFCQOUT', 'TRFCQSTATE', 'SDBAH', 'SDBAD', 'DBMSGORA', 'DDLOG',

            'APQD', 'TST01', 'TST03', 'TSPEVJOB', 'TXMILOGRAW', 'TSPEVDEV',

            'SNAP', 'SMO8FTCFG', 'SMO8FTSTP', 'SMO8_TMSG', 'SMO8_TMDAT',

            'SMO8_DLIST', 'SMW3_BDOC', 'SMW3_BDOC1', 'SMW3_BDOC2',

            'SMW3_BDOC4', 'SMW3_BDOC5', 'SMW3_BDOC6', 'SMW3_BDOC7', 'SMW3_BDOCQ', 'SMWT_TRC',

            'TPRI_PAR', 'RSBMLOGPAR', 'RSBMLOGPAR_DTP', 'RSBMNODES', 'RSBMONMESS',

            'RSBMONMESS_DTP', 'RSBMREQ_DTP', 'RSCRTDONE', 'RSDELDONE', 'RSHIEDONE',

            'RSLDTDONE', 'RSMONFACT', 'RSMONICTAB', 'RSMONIPTAB', 'RSMONMESS', 'RSMONRQTAB', 'RSREQDONE',

            'RSRULEDONE', 'RSSELDONE', 'RSTCPDONE', 'RSUICDONE',

            'VBDATA', 'VBMOD', 'VBHDR', 'VBERROR',

            'VDCHGPTR', 'JBDCPHDR2', 'JBDCPPOS2', 'SWELOG', 'SWELTS', 'SWFREVTLOG',

            'ARDB_STAT0', 'ARDB_STAT1', 'ARDB_STAT2', 'QRFCTRACE', 'QRFCLOG',

            'DDPRS', 'TBTCO', 'TBTCP', 'TBTCS', 'MDMFDBEVENT', 'MDMFDBID', 'MDMFDBPR',

            'RSRWBSTORE', 'RSRWBINDEX', '/SAPAPO/LISMAP', '/SAPAPO/LISLOG',

            'CCMLOG', 'CCMLOGD', 'CCMSESSION', 'CCMOBJLST', 'CCMOBJKEYS',

            'SXMSPMAST', 'SXMSPMAST2', 'SXMSPHIST', 'RSBATCHDATA',

            'SXMSPHIST2', 'SXMSPFRAWH', 'SXMSPFRAWD', 'SXMSCLUR', 'SXMSCLUR2', 'SXMSCLUP',

            'SXMSCLUP2', 'SWFRXIHDR', 'SWFRXICNT', 'SWFRXIPRC',

            'XI_AF_MSG', 'XI_AF_MSG_AUDIT', 'BC_MSG', 'BC_MSG_AUDIT',

            'SMW0REL', 'SRRELROLES', 'COIX_DATA40', 'T811E', 'T811ED',

            'T811ED2', 'RSDDSTATAGGR', 'RSDDSTATAGGRDEF', 'RSDDSTATCOND', 'RSDDSTATDTP',

            'RSDDSTATDELE', 'RSDDSTATDM', 'RSDDSTATEVDATA', 'RSDDSTATHEADER',

            'RSDDSTATINFO', 'RSDDSTATLOGGING', 'RSERRORHEAD', 'RSERRORLOG',

            'DFKKDOUBTD_W', 'DFKKDOUBTD_RET_W', 'RSBERRORLOG', 'INDX',

            'SOOD', 'SOOS', 'SOC3', 'SOFFCONT1', 'BCST_SR', 'BCST_CAM',

            'SICFRECORDER', 'CRM_ICI_TRACES', 'RSPCINSTANCE',

            'GVD_BGPROCESS', 'GVD_BUFF_POOL_ST', 'GVD_LATCH_MISSES',

            'GVD_ENQUEUE_STAT', 'GVD_FILESTAT', 'GVD_INSTANCE',  

            'GVD_PGASTAT', 'GVD_PGA_TARGET_A', 'GVD_PGA_TARGET_H',

            'GVD_SERVERLIST', 'GVD_SESSION_EVT', 'GVD_SESSION_WAIT',

            'GVD_SESSION', 'GVD_PROCESS', 'GVD_PX_SESSION',

            'GVD_WPTOTALINFO', 'GVD_ROWCACHE', 'GVD_SEGMENT_STAT',

            'GVD_SESSTAT', 'GVD_SGACURRRESIZ', 'GVD_SGADYNFREE',

            'GVD_SGA', 'GVD_SGARESIZEOPS', 'GVD_SESS_IO',   

            'GVD_SGASTAT', 'GVD_SGADYNCOMP', 'GVD_SEGSTAT',   

            'GVD_SPPARAMETER', 'GVD_SHAR_P_ADV', 'GVD_SQLAREA',   

            'GVD_SQL', 'GVD_SQLTEXT', 'GVD_SQL_WA_ACTIV',

            'GVD_SQL_WA_HISTO', 'GVD_SQL_WORKAREA', 'GVD_SYSSTAT',   

            'GVD_SYSTEM_EVENT', 'GVD_DATABASE', 'GVD_CURR_BLKSRV',

            'GVD_DATAGUARD_ST', 'GVD_DATAFILE', 'GVD_LOCKED_OBJEC',

            'GVD_LOCK_ACTIVTY', 'GVD_DB_CACHE_ADV', 'GVD_LATCHHOLDER',

            'GVD_LATCHCHILDS', 'GVD_LATCH', 'GVD_LATCHNAME', 

            'GVD_LATCH_PARENT', 'GVD_LIBRARYCACHE', 'GVD_LOCK',      

            'GVD_MANGD_STANBY', 'GVD_OBJECT_DEPEN', 'GVD_PARAMETER', 

            'GVD_LOGFILE', 'GVD_PARAMETER2', 'GVD_TEMPFILE',  

            'GVD_UNDOSTAT', 'GVD_WAITSTAT', 'ORA_SNAPSHOT',

            '/TXINTF/TRACE', 'RSECLOG', 'RSECUSERAUTH_CL', 'RSWR_DATA',

            'RSECVAL_CL', 'RSECHIE_CL', 'RSECTXT_CL', 'RSECSESSION_CL',

            'UPC_STATISTIC', 'UPC_STATISTIC2', 'UPC_STATISTIC3',

            'RSTT_CALLSTACK', 'RSZWOBJ', 'RSIXWWW', 'RSZWBOOKMARK', 'RSZWVIEW',

            'RSZWITEM', 'RSR_CACHE_DATA_B', 'RSR_CACHE_DATA_C', 'RSR_CACHE_DBS_BL',

            'RSR_CACHE_FFB', 'RSR_CACHE_QUERY', 'RSR_CACHE_STATS',

            'RSR_CACHE_VARSHB', 'WRI$_OPTSTAT_HISTGRM_HISTORY',

            'WRI$_OPTSTAT_HISTHEAD_HISTORY', 'WRI$_OPTSTAT_IND_HISTORY',

            'WRI$_OPTSTAT_TAB_HISTORY', 'WRH$_ACTIVE_SESSION_HISTORY',

            'RSODSACTUPDTYPE', 'TRFC_I_SDATA', 'TRFC_I_UNIT', 'TRFC_I_DEST',

            'TRFC_I_UNIT_LOCK', 'TRFC_I_EXE_STATE', 'TRFC_I_ERR_STATE',

            'DYNPSOURCE', 'DYNPLOAD', 'D010TAB', 'REPOSRC', 'REPOLOAD',

            'RSOTLOGOHISTORY', 'SQLMD', '/SDF/ZQLMD', 'RSSTATMANREQMDEL',

            'RSSTATMANREQMAP', 'RSICPROT', 'RSPCPROCESSLOG',

            'DSVASRESULTSGEN', 'DSVASRESULTSSEL', 'DSVASRESULTSCHK',

            'DSVASRESULTSATTR', 'DSVASREPODOCS', 'DSVASSESSADMIN', 'DOKCLU',

            'ORA_SQLC_HEAD', 'ORA_SQLC_DATA', 'CS_AUDIT_LOG_',

            'SWN_NOTIF', 'SWN_NOTIFTSTMP', 'SWN_SENDLOG', 'JOB_LOG',

            'SWNCMONI', 'BC_SLD_CHANGELOG', 'ODQDATA_F', 'STATISTICS_ALERTS', 'STATISTICS_ALERTS_BASE'

          ) OR

            ( TABLE_NAME LIKE 'GLOBAL%' AND SCHEMA_NAME = '_SYS_STATISTICS' ) OR

            ( TABLE_NAME LIKE 'HOST%' AND SCHEMA_NAME = '_SYS_STATISTICS' ) OR

            TABLE_NAME LIKE '/BI0/0%' OR

            TABLE_NAME LIKE '/BIC/B%'

          THEN

            'SAP Note 706478 (archiving and cleanup options)'

          ELSE

            'Application data management and archiving'

          END MEMORY_REDUCTION_APPROACHES

        FROM

        ( SELECT

            HOST,

            PORT,

            'Row store' AREA,

            SCHEMA_NAME,

            TABLE_NAME,

            SUM(TABLE_SIZE) SIZE_BYTE

          FROM

          ( SELECT

              HOST,

              PORT,

              SCHEMA_NAME,

              TABLE_NAME,

              ALLOCATED_FIXED_PART_SIZE + ALLOCATED_VARIABLE_PART_SIZE TABLE_SIZE

            FROM

              M_RS_TABLES

            UNION ALL

            ( SELECT

                HOST,

                PORT,

                SCHEMA_NAME,

                TABLE_NAME,

                INDEX_SIZE TABLE_SIZE

              FROM

                M_RS_INDEXES

            )

          )

          GROUP BY

            HOST,

            PORT,

            SCHEMA_NAME,

            TABLE_NAME

          UNION ALL

          ( SELECT

              HOST,

              PORT,

              'Column store' AREA,

              SCHEMA_NAME,

              TABLE_NAME,

              SUM(MEMORY_SIZE_IN_TOTAL) SIZE_BYTE

            FROM

              M_CS_TABLES   

            GROUP BY

              HOST,

              PORT,

              SCHEMA_NAME,

              TABLE_NAME

          )

        )

      )

    ) D

    WHERE

      D.HOST LIKE BI.HOST AND

      TO_CHAR(D.PORT) LIKE BI.PORT AND

      ( BI.INCLUDE_OVERLAPPING_HEAP_AREAS = 'X' OR

        D.DETAIL NOT IN

        ( 'Pool/AttributeEngine',

          'Pool/AttributeEngine/Delta',

          'Pool/AttributeEngine/Delta/BtreeDictionary',

          'Pool/AttributeEngine/Delta/Cache',

          'Pool/AttributeEngine/Delta/InternalNodes',

          'Pool/AttributeEngine/Delta/LeafNodes',

          'Pool/AttributeEngine/idattribute',

          'Pool/AttributeEngine/idattribute/build-reverse-index',

          'Pool/AttributeEngine-IndexVector-BlockIndex',

          'Pool/AttributeEngine-IndexVector-BTreeIndex',

          'Pool/AttributeEngine-IndexVector-Single',

          'Pool/AttributeEngine-IndexVector-SingleIndex',

          'Pool/AttributeEngine-IndexVector-Sp-Cluster',

          'Pool/AttributeEngine-IndexVector-Sp-Indirect',

          'Pool/AttributeEngine-IndexVector-Sp-Prefix',

          'Pool/AttributeEngine-IndexVector-Sp-Rle',

          'Pool/AttributeEngine-IndexVector-Sp-Sparse',

          'Pool/malloc/libhdbbasement.so',

          'Pool/malloc/libhdbcs.so',

          'Pool/malloc/libhdbcsstore.so',

          'Pool/NameIdMapping/RoDict',

          'Pool/RowEngine/CpbTree',

          'StackAllocator'

       )

      ) AND

      ( BI.AREA = '%' OR

        BI.AREA = 'HEAP'   AND D.AREA = 'Heap area' OR

        BI.AREA = 'ROW'    AND D.AREA = 'Row store' OR

        BI.AREA = 'COLUMN' AND D.AREA = 'Column store' OR

        BI.AREA = 'CODE'   AND D.AREA = 'Code' OR

        BI.AREA = 'STACK'  AND D.AREA = 'Stack'

      )

  )

  GROUP BY

    CASE WHEN AGGREGATE_BY = 'NONE' OR INSTR(AGGREGATE_BY, 'HOST')   != 0 THEN HOST          ELSE MAP(BI_HOST, '%', 'any', BI_HOST) END,

    CASE WHEN AGGREGATE_BY = 'NONE' OR INSTR(AGGREGATE_BY, 'PORT')   != 0 THEN TO_CHAR(PORT) ELSE MAP(BI_PORT, '%', 'any', BI_PORT) END,

    CASE WHEN AGGREGATE_BY = 'NONE' OR INSTR(AGGREGATE_BY, 'AREA')   != 0 THEN AREA          ELSE MAP(BI_AREA, '%', 'any', BI_AREA) END,

    CASE WHEN AGGREGATE_BY = 'NONE' OR INSTR(AGGREGATE_BY, 'DETAIL') != 0 THEN DETAIL        ELSE 'any'                             END,

    AGGREGATE_BY,

    TOTAL_USED_BYTE,

    RESULT_ROWS,

    MIN_SIZE_PCT

  ORDER BY

    SUM(SIZE_BYTE) DESC

)

WHERE

  ( MIN_SIZE_PCT = -1 OR SIZE_PCT_ORIG >= MIN_SIZE_PCT ) AND

  ( RESULT_ROWS = -1 OR ROW_NUM <= RESULT_ROWS )

 

But, I am struck with syntax errors. You mean, exactly, the same text file? If yes, do i have to execute the above program in HANA studio? If yes, can you send me an example, stating, what modifications has to be done in above program?

 

 

Thanks & best regards,

Sreenu


Viewing all articles
Browse latest Browse all 3585

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>