Uploaded image for project: 'Application Server 3  4  5 and 6'
  1. Application Server 3 4 5 and 6
  2. JBAS-289

Incorrect SQL with OR and IS NOT EMPTY

    XMLWordPrintable

Details

    Description

      SourceForge Submitter: jboynes .
      Opening this as 621270 has been closed.

      Incorrect SQL is generated for EJB-QL where IS NOT
      EMPTY is used in a OR condition such as:
      SELECT OBJECT(p)
      FROM parent p
      WHERE p.children IS NOT EMPTY
      OR p.value = ?1

      generates

      SELECT t0_p.id
      FROM Parent t0_p, Child t1_p_children
      WHERE ((1=1) OR t0_p.value = ?) – <---- oops
      AND (t0_p.id=t1_p_children.parent)

      Attachments

        Activity

          People

            starksm64 Scott Stark (Inactive)
            sourceforge-user SourceForge legacy user (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: