jsr-333
  1. jsr-333
  2. JSR_333-55

expand SQL2 (inspired by modeshape)

    Details

    • Type: Improvement Improvement
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Won't Fix
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: None
    • Labels:
      None

      Description

      https://docs.jboss.org/author/display/MODE/Query+and+search#Queryandsearch-JCRSQLandJCRSQL2extensions

      imho of importance are the following:
      Removing duplicate rows with SELECT DISTINCT ...
      Limit the number of rows returned with LIMIT count
      Skip initial rows with OFFSET number
      Constrain the depth of a node with DEPTH(selectorName)
      Constrain the path of a node with PATH(selectorName)
      Constrain the references from a node with REFERENCE(selectorName.property) and REFERENCE(selectorName)
      Use pseudo-columns to include the path, score, node name, node local name, and node depth in result columns or in criteria

        Activity

        Hide
        rhauch added a comment -

        I generally agree with Thomas' comments, including those about which features might be optional. In particular, both correlated and non-correlated subqueries should be optional. (For the record, we added support for non-correlated because we needed better ways of dynamically specifying a range of values for criteria. I'm not sure when/if we'll support correlated.)

        > "mode:localName" and "mode:depth": I'm not sure if they should not be supported, as they are simply synonyms for localname() and depth(). If we do want to support them, then we should rename them.

        +1 for renaming them. We would have used "jcr:localName" and "jcr:depth", except we didn't want to start expanding the "jcr" namespace with custom extensions. We can very easily support the new and old names at the same time, should these be added to JSR-333.

        > I would like to add an operator to concatenate text: ||

        +1

        > About using double quotes to quote identifiers: I think the next JCR specification should at least deprecate (if not disallow) support for double quotes for string literals.

        I'm fine with deprecating, but I would argue against disallowing it since JSR-333 will be a point release (e.g., 2.1) and IMO any queries that were allowed in 2.0 should be allowed in 2.1.

        Show
        rhauch added a comment - I generally agree with Thomas' comments, including those about which features might be optional. In particular, both correlated and non-correlated subqueries should be optional. (For the record, we added support for non-correlated because we needed better ways of dynamically specifying a range of values for criteria. I'm not sure when/if we'll support correlated.) > "mode:localName" and "mode:depth": I'm not sure if they should not be supported, as they are simply synonyms for localname() and depth(). If we do want to support them, then we should rename them. +1 for renaming them. We would have used "jcr:localName" and "jcr:depth", except we didn't want to start expanding the "jcr" namespace with custom extensions. We can very easily support the new and old names at the same time, should these be added to JSR-333. > I would like to add an operator to concatenate text: || +1 > About using double quotes to quote identifiers: I think the next JCR specification should at least deprecate (if not disallow) support for double quotes for string literals. I'm fine with deprecating, but I would argue against disallowing it since JSR-333 will be a point release (e.g., 2.1) and IMO any queries that were allowed in 2.0 should be allowed in 2.1.
        Hide
        reschke added a comment -

        This would need to be added to JQOM as well, right?

        Show
        reschke added a comment - This would need to be added to JQOM as well, right?
        Hide
        rhauch added a comment -

        Yes. You can see the ModeShape API extensions in our JavaDoc and codebase. Although the Java interfaces in the 'org.modeshape.jcr.api.query.qom' package are currently licensed with LGPL 2, all of the people that modified those interfaces would be happy to contribute all or parts of them to JSR-333. (After all, they are just interfaces.)

        Show
        rhauch added a comment - Yes. You can see the ModeShape API extensions in our JavaDoc and codebase . Although the Java interfaces in the 'org.modeshape.jcr.api.query.qom' package are currently licensed with LGPL 2, all of the people that modified those interfaces would be happy to contribute all or parts of them to JSR-333. (After all, they are just interfaces.)
        Hide
        Peeter Piegaze added a comment -

        So we have just passed the public review. The next step is to fix up a few smallish bugs and submit the "proposed final draft". There are about 4-5 small bugs, and then there is this one

        At this point in the process, and given my own workload (and my employer's priorities wrt that) I have to say that I cannot see putting the modeshape stuff into the spec.

        So, unless someone volunteers to do the work, and do it well, and to do it relatively quickly (that includes changes in the spec document itself as well) I am going to to have to WONTFIX this one. Sorry.

        Re-open if you are serious about taking on this job

        Show
        Peeter Piegaze added a comment - So we have just passed the public review. The next step is to fix up a few smallish bugs and submit the "proposed final draft". There are about 4-5 small bugs, and then there is this one At this point in the process, and given my own workload (and my employer's priorities wrt that) I have to say that I cannot see putting the modeshape stuff into the spec. So, unless someone volunteers to do the work, and do it well, and to do it relatively quickly (that includes changes in the spec document itself as well) I am going to to have to WONTFIX this one. Sorry. Re-open if you are serious about taking on this job
        Hide
        Peeter Piegaze added a comment -

        WONTFIX due to resource_constraint@ppiegaze

        Show
        Peeter Piegaze added a comment - WONTFIX due to resource_constraint@ppiegaze

          People

          • Assignee:
            Unassigned
            Reporter:
            lsmith77
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: