Getting Two and More Document with same Document id

the query is
select Meta(profile_detail).id from profile_detail where type=‘doctor’ and _deleted is missing and uid=‘doctor_54ea9784-7428-44ec-b37e-ae9ceb07ba30’;
and the output we got is

[
{
“id”: “_sync:rb:R8A1Z5epewswSJFTsBv0+yieW2iF5xBomulSf8h5xrM=”
},
{
“id”: “_sync:rb:lJo5+2bgfek5otHWGqnd1AoHBRQA5OkddqgbZIO4mUU=”
},
{
“id”: “doctor_54ea9784-7428-44ec-b37e-ae9ceb07ba30”
}
]

and another query that we are running is

select count(uid),uid from profile_detail where type=‘doctor’ and _deleted is missing group by uid;

OUTPUT we can find in

Attachment