OpenJPA
  1. OpenJPA
  2. OPENJPA-875 OpenJPA 2.0 iteration 4 primary task
  3. OPENJPA-879

JPA2 Query support for general and qualified identification variable

    Details

    • Type: Sub-task Sub-task
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 2.0.0-M2
    • Fix Version/s: 2.0.0-M2
    • Component/s: None
    • Labels:
      None

      Description

      support query syntax of followings in path expressions :
      1. Key(identifier)
      2. Value(identifier)
      3. Entry(identifier)

        Activity

        Hide
        Catalina Wei added a comment -

        Code committed in revision r750517 supports general/qualified identification variables appear in selections:

        examples:
        select KEY(e) from PhoneNumber p, in (p.emps) e

        select ENTRY(e) from PhoneNumber p, in (p.emps) e

        select VALUE(e) from PhoneNumber p, in (p.emps) e

        in which emps is a relation field of java type Map<K,V> .

        JPA2 JPQL syntax allows qualified identification variables to appear in single_valued_path_expression, which implies that
        KEY(e) and VALUE(e) can be used to as a path and also can be further navigated to its fields or relations. Those support will be added in iteration 5.

        More testcases will be added to cover additional annotations using @MapKeyClass and @MapKeyJoinColumns.

        Show
        Catalina Wei added a comment - Code committed in revision r750517 supports general/qualified identification variables appear in selections: examples: select KEY(e) from PhoneNumber p, in (p.emps) e select ENTRY(e) from PhoneNumber p, in (p.emps) e select VALUE(e) from PhoneNumber p, in (p.emps) e in which emps is a relation field of java type Map<K,V> . JPA2 JPQL syntax allows qualified identification variables to appear in single_valued_path_expression, which implies that KEY(e) and VALUE(e) can be used to as a path and also can be further navigated to its fields or relations. Those support will be added in iteration 5. More testcases will be added to cover additional annotations using @MapKeyClass and @MapKeyJoinColumns.

          People

          • Assignee:
            Catalina Wei
            Reporter:
            Catalina Wei
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development