Uploaded image for project: 'Hibernate ODM'
  1. Hibernate ODM
  2. HIBERNATE-71

'is Null' ('is not null') MQL translation

    • Type: Icon: Task Task
    • Resolution: Unresolved
    • Priority: Icon: Unknown Unknown
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      We need to translate `is null` and `is not null` into MQL counterparts. See the example below from Hibernate user guide relevant part (https://docs.jboss.org/hibernate/orm/6.6/userguide/html_single/Hibernate_User_Guide.html#hql-null-predicate):

      // select all persons with a nickname
      List<Person> persons = entityManager.createQuery(
      	"select p " +
      	"from Person p " +
      	"where p.nickName is not null",
      	Person.class)
      .getResultList();
      
      // select all persons without a nickname
      List<Person> persons = entityManager.createQuery(
      	"select p " +
      	"from Person p " +
      	"where p.nickName is null",
      	Person.class)
      .getResultList(); 

            Assignee:
            nathan.xu@mongodb.com Nathan Xu
            Reporter:
            nathan.xu@mongodb.com Nathan Xu
            None
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated: