SQLite Forum

Help rewriting a query to match the speed of a 2nd query
> but is there a way to rewrite the second without the the duplication of IN groups?

If you mean just without having to type/bind the values twice, then how about

with ProjIDs as (values ('PR0000014888'),
select ...
where b.ProjID in ProjIDs
where a.ProjID in ProjIDs