Quantcast
Channel: SCN: Message List - SAP Adaptive Server Enterprise (SAP ASE) for Custom Applications
Viewing all articles
Browse latest Browse all 3587

Re: optimize union in ase query

$
0
0

Although I cannot send DDLs they allowed me to run and post the result for the "missing stats" script proposed by Abdelhak and I attach it along with the plan when I used "parallel" hints. I shall also try to decipher it.

 

Concerning the temporary tables solution, it may seem strange but the decision not to use it is not mine, so I didn't focus on it. All these suggestions are very interesting and helpful and they you a lot for your effort. Also Jeff said that parallel run is meaningless for a query returning a few rows, here it returns only 35 rows. Finally the idea for

query 1

union

query 2

union all

query 3

union

query 4

 

fits in our case, I mean that it is true that the second union can be replaced by union all, but again it had no effect on execution duration.

Thank you all a lot for your valuable help.


Viewing all articles
Browse latest Browse all 3587

Trending Articles



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