the following assessment in the Cypher Indexes and Constraints course seems to be wrong and might actually lead to a wrongful implementation and assumption of index usage.
As I understand non of the current available indexes would improve this query. Looking for a value in an indexed array property will in fact NOT use an index for lookup.
Please correct me if I am wrong and show me how an Index could be used on an actual multivalued property to find a specific value like in the example.
I would really, really like to be wrong about that
This is a BAD question that needs to be rewritten. You are absolutely correct! Cypher does not (yet) support indexes on array elements. It will be a a future release.
Thank you for pointing this out. I will change the example.
That KB article is a general purpose description of how data is stored in the db.
In 5.0, there is now support for string arrays in full text indexes https://neo4j.com/release-notes/database/neo4j-5/
In 5.0, there is NOW support for string arrays in full text indexes
Nice. But I have to convert my integer IDs to strings, define a fulltext index using the keyword analyzer and then start all my queries by a procedure call to retrieve the matching nodes instead of letting the query planner do its job like with a normal index.
And it is still weird that in 4.4. you can define a b-tree index on any array property that will never get used.