Hi all,
I'm using H2 2.2.224 and noticed that when querying a linked table like this: sql SELECT id FROM tbl WHERE createdAt > '2024-04-01' LIMIT 100; it fetches all rows from the remote DB, and only then applies the limit. EXPLAIN ANALYZE shows reads: matching total row count, and it's very slow. >From the code, it looks like LinkedIndex.find() doesn’t include LIMIT when generating the SQL sent to the remote DB. https://github.com/h2database/h2database/blob/master/h2/src/main/org/h2/index/LinkedIndex.java#L90-L110 Is this expected? Or is LIMIT just not supported yet in linked table queries? Thanks! -- You received this message because you are subscribed to the Google Groups "H2 Database" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion visit https://groups.google.com/d/msgid/h2-database/008bc838-6d10-4e5d-890a-bdb11197b47en%40googlegroups.com.
