Hi All,
I havepartitioned (by date), splayed and segmented (by exchange) database. Very oftenI have query like this:
Select from t where date = 2014.07.01, market = xyz
Where xyzmarket is part of specific exchange. The execution of this query is decomposedfor each segment, but only one is the right one, so the perf of the query isvery bad.
Ihave parted attribute on market, but it doesnt help a lot, because it stillsearch in each segment, and the query is very slow. I can add slaves forthe q process, so the subqueries on each segment will run parallely, butits not nice and efficient solution (I have more segments than licensedcores).
Thismodification of the query:
select from`$“:/…/rightSegmentName/2014.07.01/t” where market = m
runs muchfaster. So I can write a new function select2, which composed and execute thisfaster query (this function needs a dictionary where key is market and value issegment). Any other idea? I dont want to leave the segment setup, because ofother aspect.
Thanks!
Pavel