QLDB doing a full table scan when using an OR across two indexed fields

1

We have a table T with two indexed fields A and B. When we query the table using the following query, QLDB does a full table scan (by evidence of the IO stats and latency):

select * from T where A = 'x' or B = 'y'

Why? And is that expected?

Andrew
已提问 8 个月前214 查看次数
1 回答
0

Well, a team member just pointed out that it is not supported according to this https://qldbguide.com/guide/data-design/#transaction-timeout

 --Multiple indexed fields (VIN, LicensePlateNumber) lookup using the OR operator
 --Disjunctions not currently supported 
 SELECT * FROM VehicleRegistration
 WHERE VIN = '1N4AL11D75C109151' OR LicensePlateNumber = 'LEWISR261LL'

This seems like a bizarre omission.

Andrew
已回答 8 个月前

您未登录。 登录 发布回答。

一个好的回答可以清楚地解答问题和提供建设性反馈,并能促进提问者的职业发展。

回答问题的准则