CRUD API: How to get user by date?

I have created a date entity in java : private Date dateFrom. I can add this to the database but I'm unable to get the user by date through postman due to the date format Z that get's added to the end of date after adding to database. How do I remove this part?

public class ExampleAPI {
        public List<User> getUserByDateJoin(@PathParam("dateFrom") Date dateFrom) {
            return manageUserBean.getUserByDateJoin(dateFrom);

public class ManageUserBean  {
            public User addUser(User user)  {
                    entityManager.flush(); // stores the user to the db
                    return user;
           @PersistenceContext(unitName = "users")
            private EntityManager entityManager;
            public List<User> getUserByDateJoin(Date dateFrom) {
                Query q = entityManager.createQuery("SELECT u FROM User u where u.dateFrom= :dateFrom");
                return (List<User>) q.getResultList();