users@glassfish.java.net

Re: Case Insensitve Queries

From: <glassfish_at_javadesktop.org>
Date: Wed, 14 Mar 2007 23:35:32 PST

HI.

Using EQL you should be able to use the UPPER functional expression like in the following query:

[code]
Query q = em.createQuery("select b from SomeEntityClass b where UPPER(fieldname) = UPPER(:parameter)");
q.setParameter("parameter", "jOhN");
[/code]

That's all.

Alexander.
[Message sent by forum member 'sahlix' (sahlix)]

http://forums.java.net/jive/thread.jspa?messageID=207998