Hi Santosh,
According to your information, the 5,000 records, it takes 4 minutes for all?
As my understanding, it is much time and performance is not good for only 5,000 records, general, row store type in other DB product, such as DB2, Oracle, SQL Server. the performance is not good for 5,000 records and takes 4 minutes, if the records is greater than 1,000,000, then I think that the execution result is very very bad.
Besides, as you know, the SAP HANA performance is faster than other DB product.
So I think that you need to check and consider your solution again.
Regards
Jerry