Uploaded image for project: 'OpenJPA'
  1. OpenJPA
  2. OPENJPA-864

Subquery problems with SYNTAX_DATABASE (Oracle)

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 1.0.3, 1.2.0
    • Fix Version/s: 1.0.4, 1.2.1, 1.3.0, 2.0.0-M2
    • Component/s: None
    • Labels:
      None

      Description

      The following query does not generate the correct SQL with Oracle :
      "SELECT e,d from Employee e, Dependent d "
      + "WHERE e.empId = :empid "
      + "AND d.id.empid = (SELECT MAX (e2.empId) FROM Employee e2) "
      + "AND d.id.effDate > :minDate "
      + "AND d.id.effDate < :maxDate ";

      The problem will exist with any DBDictionary that uses JoinSyntaxes.SYNTAX_DATABASE (no joins will be created for Dependent).

        Attachments

          Activity

            People

            • Assignee:
              mikedd Michael Dick
              Reporter:
              mikedd Michael Dick
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: