In class Users, I have a field id, firstname, lastname, username, password, enabled.
Enabled field is boolean
When i use do this query by example with spring
Users users = new Users();
users.setId(12);
Example<Users> example = Example.of(users);
Page<Users> pageUsers = userRepository.findAll(example, page);
In the generated query, i see in the where condition, it search on id field and enabled
why it's search on enabled?
You are using "boolean" primitive type, so your "Example" object has implicitly the "false" value.. you can use "Boolean" type to fix it