#primary index already exists, but 'not online'

hi @james, can you check the indexer log for any errors/warnings. Can you verify indexer process is up & running, and are you able to run other queries with secondary indexes?

Try restarting Couchbase services, and drop/recreate the primary index.
Btw, what is the couchbase version & OS/platform?

-Prasad