Hi team, I am trying to remove sort index on one o...
# troubleshooting
s
Hi team, I am trying to remove sort index on one of the columns and have tried reloading all segments. still the segments after reloading still show sorting true and is appearing in queries.
m
Reload won't change sorting
s
Then?
m
What is your goal?
s
I would like this query to use inverted index on brand id after pruning with range index on creaed_at
m
is this realtime or offline?
s
realtime
m
Sorted index is not a separate file that can be removed. It is the way data is stored that it duals as data + index. So you cannot really remove it
You can check SegmentRefreshTask to sort it on another column
s
why is the query not using range index first?
segment refresh or reload?
m
Minon task
sorted index gets priority
s
@Mayank I ran a refresh task. but the segment that got refreshed still has isSorted true for brandId
m
Wait, your first screenshot said sorted on created_at? Sorted index is better than inv index in general, why do you want to remove sorted index from brand id?
s
yes, sort index was their on both created at and brandid. have removed on brand Id but not taking effect. My segment pruning is based on time so I want the range index on created at to work first.
m
Pruning on time doesn’t depend on range index or sorted index, it depends on the metadata that stores min/max time value per segment