String comparison in query where clause

#1

I am having trouble getting a simple string comparison to work in an SQL "where" clause.  It is my understanding that queries are case sensitive by default and I do not want that, so I am constructing the query as follows...

SELECT e FROM Exercise AS e WHERE UPPER(e.name) = ?0

and then I am converting the parameter (representing by position ?0) to upper case.  I am certain the parameter value is correct, and there should be a matching record in the database, but my query returns no result.

Is there a more appropriate way to do simple case-insensitive queries using JPA?

#2

After looking at this issue further it was found that it was a programmer error, and it is not an ObjectDB-related issue or question.  I would like to just remove the thread from the forum complete.  Can you do that?

#3

Thank you for this update.

For the sake of other users of this forum who may track this thread it would be better to close this thread now but not to remove it (at least yet).

ObjectDB Support

Reply