How to delete a document based on other attribute that is not a key?

How to delete a document that is not a key? for e.g delete on date or status?
Should I be querying for date or status and delete document one by one?

Hi @rkunhi query does have support for the DELETE statement (https://docs.couchbase.com/server/current/n1ql/n1ql-language-reference/delete.html) which might do what you want? Alternatively, a query returning the specific keys to delete and then using KV to delete them would also work. https://docs.couchbase.com/go-sdk/current/howtos/concurrent-async-apis.html might be of help for deleting a large number of keys, using either gocb’s bulk operations API (RemoveOp) or rolling your own using goroutines.