Hello I am observing a bug where same query with j...
# troubleshooting
s
Hello I am observing a bug where same query with just difference in ordering of filters is yielding different results for multi stage engine. Can anyone suggest what is happening and how to fix this. We cannot have such bugs in prod environment. select count(*) from tablename WHERE arraytomv(colname) NOT IN (2113) AND arraytomv(colname) IN (211) — yields 70749000 records select count(*) from tablename WHERE arraytomv(colname) IN (211) AND arraytomv(colname) NOT IN (2113) — yields 75849000 The order of NOT IN clause and IN clause in filter is determining different results. 70749000 is the correct results which we validated without the multistage engine. Please suggest what is causing this and any workaround for this. @Mayank @Jackie @Xiang Fu
x
which version are you running? cc: @Gonzalo Ortiz @Bolek Ziobrowski @Yash Mayya
s
1.2.0
x
ack
have you tried this query in v1?
is the result same
s
without multi stage it works fine.. results are same for both queries
x
ack, thanks for clarify!
s
Does
select count(*) from tablename WHERE (arraytomv(colname) IN (211)) AND (arraytomv(colname) NOT IN (2113))
change the results at all? Added () around each part of the WHERE clause.
s
Still same issue
y
This is a bug in 1.2.0 that should be fixed in 1.3.0, can you try this with 1.3.0? This commit should've fixed the issue - https://github.com/apache/pinot/pull/13618.
s
Thank you. The issue seems to be resolved in 1.3 version.