CREATE INDEX `TestTableQuery_tags_type` ON `TestDb` . `TestTableQuery` . `TestCollection` ( DISTINCT `tags` )
WHERE type = "TestTableQuery";
SELECT COUNT(1) AS count
FROM `TestDb` . `TestTableQuery` . `TestCollection` AS t
WHERE t.type = "TestTableQuery" AND ANY tag IN tags SATISFIES tag = "red" END;