Implemented match entities in entity manager