‎2015 Nov 21 9:09 AM
Hi Experts,
I know that cluster/pool tables when migrated to HANA database gets converted to transparent table because of which explicit sorting is required in existing ABAP codes like adding order by clause while fetching data from pool/cluster table.
But my question here is...what about the already existing transparent table's behavior after migrating to HANA DB ?
Is it required to sort the data fetched from transparent tables ?
Thanks
Punit
‎2015 Nov 22 5:05 PM
Hello Punit,
a select statement on HANA returns the data in most cases in a different order than other database systems. The reason is the different data materialization behavior.
So at every position where the order of the selected data is relevant the data has to be sorted explicitly (either by ORDER BY in the select clause or a SORT). For instance if you select a collection of data and in the ABAP program you read the first entry the behavior can be different on HANA compared to another DB system if you do not have sorted the data.
SAP provides the CodeInspector check variant FUNCTIONAL_DB which does several checks regarding the behavior of ABAP programs running with HANA. One check is the "Search problematic statements for result of SELECT/OPEN CURSOR without ORDER BY". You can check your programs with that variant to find (nearly almost) positions which need to be adapted.
Best Regards,
Florian
‎2015 Nov 22 5:05 PM
Hello Punit,
a select statement on HANA returns the data in most cases in a different order than other database systems. The reason is the different data materialization behavior.
So at every position where the order of the selected data is relevant the data has to be sorted explicitly (either by ORDER BY in the select clause or a SORT). For instance if you select a collection of data and in the ABAP program you read the first entry the behavior can be different on HANA compared to another DB system if you do not have sorted the data.
SAP provides the CodeInspector check variant FUNCTIONAL_DB which does several checks regarding the behavior of ABAP programs running with HANA. One check is the "Search problematic statements for result of SELECT/OPEN CURSOR without ORDER BY". You can check your programs with that variant to find (nearly almost) positions which need to be adapted.
Best Regards,
Florian
‎2015 Nov 22 7:16 PM
Hi Florian,
Thanks for your reply!!
But I referred Note 1794490 which states that only pool/cluster tables which are converted to transparent table on HANA requires explicit sorting.
Are you saying that even existing transparent tables requires explicit sorting. If yes then do you have any OSS note or document supporting this?
Thanks
Punit
‎2015 Nov 22 7:36 PM
Please check documentation ABAP Test Cockpit and Code Inspector in Context of HANA Migration - SQL Performance Monitoring - SAP... and the mentioned note 1912445.
Regards,
Florian