Updated count objects using query map to use its own bean