I would like to select a list of results from the database, but the statement ==for JDO queries is case sensitive. Is there a way to select "USER", "User" and "User" from the table using a single parameter?
In MySQL, you have a statement LIKE, and in Java, a function equalsIgnoreCase. However, none of them work in this example.
PersistenceManager pm = JDO.factory.getPersistenceManager();
Query query = pm.newQuery(User.class, "username == usernameParam");
query.declareParameters("String usernameParam");
List<User> results = (List<User>) query.execute(username);
source
share