You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@openjpa.apache.org by "Pinaki Poddar (JIRA)" <ji...@apache.org> on 2009/07/24 00:16:14 UTC

[jira] Created: (OPENJPA-1195) Allow datastore function as query expression

Allow datastore function as query expression
--------------------------------------------

                 Key: OPENJPA-1195
                 URL: https://issues.apache.org/jira/browse/OPENJPA-1195
             Project: OpenJPA
          Issue Type: New Feature
            Reporter: Pinaki Poddar
            Assignee: Pinaki Poddar


Create a query expression that uses a datastore function such as MOD(..) or MAX(..) in a generic fashion.

This is required by function() support for CriteriaQuery and adds a generic capability for queries so we can query something like

  "select  CURRENT_USER(), x.name FROM Person x WHERE LENGTH(x.name)>10 ORDER BY LENGTH(x.name)"

Notice that JPQL Parser may not like the syntax -- but CriteriaQuery will allow such possibility.

Allow the function() to accept 0 or more arguments as expressions.


-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Resolved: (OPENJPA-1195) Allow datastore function as query expression

Posted by "Pinaki Poddar (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/OPENJPA-1195?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Pinaki Poddar resolved OPENJPA-1195.
------------------------------------

    Resolution: Fixed

> Allow datastore function as query expression
> --------------------------------------------
>
>                 Key: OPENJPA-1195
>                 URL: https://issues.apache.org/jira/browse/OPENJPA-1195
>             Project: OpenJPA
>          Issue Type: New Feature
>          Components: query
>    Affects Versions: 2.0.0
>            Reporter: Pinaki Poddar
>            Assignee: Pinaki Poddar
>             Fix For: 2.0.0
>
>
> Create a query expression that uses a datastore function such as MOD(..) or MAX(..) in a generic fashion.
> This is required by function() support for CriteriaQuery and adds a generic capability for queries so we can query something like
>   "select  CURRENT_USER(), x.name FROM Person x WHERE LENGTH(x.name)>10 ORDER BY LENGTH(x.name)"
> Notice that JPQL Parser may not like the syntax -- but CriteriaQuery will allow such possibility.
> Allow the function() to accept 0 or more arguments as expressions.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (OPENJPA-1195) Allow datastore function as query expression

Posted by "Pinaki Poddar (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/OPENJPA-1195?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12737901#action_12737901 ] 

Pinaki Poddar commented on OPENJPA-1195:
----------------------------------------

Thanks for pointing this out.
While we need JPQL grammar to be extended to get similar feature -- this one is part of CriteriaQuery API.
The new kernel level expression and update for variable-length function argument introduced by this current issue, perhaps, will be useful in JPQL case too, if we decide to extend the grammar.

> Allow datastore function as query expression
> --------------------------------------------
>
>                 Key: OPENJPA-1195
>                 URL: https://issues.apache.org/jira/browse/OPENJPA-1195
>             Project: OpenJPA
>          Issue Type: New Feature
>          Components: query
>    Affects Versions: 2.0.0
>            Reporter: Pinaki Poddar
>            Assignee: Pinaki Poddar
>             Fix For: 2.0.0
>
>
> Create a query expression that uses a datastore function such as MOD(..) or MAX(..) in a generic fashion.
> This is required by function() support for CriteriaQuery and adds a generic capability for queries so we can query something like
>   "select  CURRENT_USER(), x.name FROM Person x WHERE LENGTH(x.name)>10 ORDER BY LENGTH(x.name)"
> Notice that JPQL Parser may not like the syntax -- but CriteriaQuery will allow such possibility.
> Allow the function() to accept 0 or more arguments as expressions.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (OPENJPA-1195) Allow datastore function as query expression

Posted by "Pinaki Poddar (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/OPENJPA-1195?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Pinaki Poddar updated OPENJPA-1195:
-----------------------------------

          Component/s: query
    Affects Version/s: 2.0.0
        Fix Version/s: 2.0.0

> Allow datastore function as query expression
> --------------------------------------------
>
>                 Key: OPENJPA-1195
>                 URL: https://issues.apache.org/jira/browse/OPENJPA-1195
>             Project: OpenJPA
>          Issue Type: New Feature
>          Components: query
>    Affects Versions: 2.0.0
>            Reporter: Pinaki Poddar
>            Assignee: Pinaki Poddar
>             Fix For: 2.0.0
>
>
> Create a query expression that uses a datastore function such as MOD(..) or MAX(..) in a generic fashion.
> This is required by function() support for CriteriaQuery and adds a generic capability for queries so we can query something like
>   "select  CURRENT_USER(), x.name FROM Person x WHERE LENGTH(x.name)>10 ORDER BY LENGTH(x.name)"
> Notice that JPQL Parser may not like the syntax -- but CriteriaQuery will allow such possibility.
> Allow the function() to accept 0 or more arguments as expressions.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.