See https://glassfish.dev.java.net/issues/show_bug.cgi?id=572 for more information.
Do not use this type of query.