Are you able to share a list of your sets name? I wanted to double check that you are not using any forbidden characters like “:” or “;” in the set names.
asinfo -v sets -l
Most likely you have the same PK in different sets. You can check for illegal characters in set names using this guide.
or running:
asadm --no-config-file -e "asinfo -v sets -l"|sed -e 's/:objects.*//g'
Another possibility is that you have some records with null sets. (no sets specified when they were written). A scan on the namespace would show two records (1 with no set name and 1 with a set name.)
example with two records:
aql> INSERT INTO test.demo (PK, foo, bar) VALUES ('key1', 123, 'abc')
OK, 1 record affected.
aql> INSERT INTO test (PK, foo, bar) VALUES ('key1', 123, 'abc')
OK, 1 record affected.
aql> select * from test.demo
+-----+-------+
| foo | bar |
+-----+-------+
| 123 | "abc" |
+-----+-------+
1 row in set (0.076 secs)
OK
aql> select * from test
+-----+-------+
| foo | bar |
+-----+-------+
| 123 | "abc" |
| 123 | "abc" |
+-----+-------+
2 rows in set (0.074 secs)
OK