I have created an index like:
CREATE INDEX on customer (name, surname);
When I query this way: SELECT count() from customer where name=“Paul” or surname=“Walker”; the index dont work. On EXPLAIN it shows me that is using the primary index.
But when I query SELECT count() from customer where name=“Paul” and surname=“Walker”; It uses the index, whats is happening?