If the array filed in the document us a1
SELECT du.* FROM default AS d UNNEST d.a1 AS du
WHERE du.DeptCode = "FOE" AND RoleCode = "HOD";
https://docs.couchbase.com/server/5.5/n1ql/n1ql-language-reference/indexing-arrays.html
Also Checkout “Where” clause inside array not working