You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@jackrabbit.apache.org by "James Gadbury (JIRA)" <ji...@apache.org> on 2010/03/11 14:01:28 UTC

[jira] Created: (JCR-2561) SQL2 query - supplying column selector fails with NPE on getColumnName()

SQL2 query - supplying column selector fails with NPE on getColumnName()
------------------------------------------------------------------------

                 Key: JCR-2561
                 URL: https://issues.apache.org/jira/browse/JCR-2561
             Project: Jackrabbit Content Repository
          Issue Type: Bug
          Components: jackrabbit-jcr-commons
    Affects Versions: 2.0.0
            Reporter: James Gadbury


I am preparing and executing an SQL2 query (JCR 2.0) as follows:

QueryManager qm = jcrSession.getWorkspace().getQueryManager();
String queryString = "select order.[customerAccountUUID] as cust from [atl:order] as order";
Query query = qm.createQuery(queryString, Query.JCR_SQL2);
QueryResult queryResult = query.execute();

The following query fails:

select order.[customerAccountUUID] from [atl:order] as order

java.lang.NullPointerException
        org.apache.jackrabbit.commons.query.sql2.QOMFormatter.isSimpleName(QOMFormatter.java:577)
        org.apache.jackrabbit.commons.query.sql2.QOMFormatter.formatName(QOMFormatter.java:567)
        org.apache.jackrabbit.commons.query.sql2.QOMFormatter.format(QOMFormatter.java:452)
        org.apache.jackrabbit.commons.query.sql2.QOMFormatter.format(QOMFormatter.java:123)
        org.apache.jackrabbit.commons.query.sql2.QOMFormatter.format(QOMFormatter.java:117)

line 452: c.getColumnName() returns null.

The following query is fine:

select order.[customerAccountUUID] as cust from [atl:order] as order

I have been using the test case (here: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-spi-commons/src/test/resources/org/apache/jackrabbit/spi/commons/query/sql2/test.sql2.txt?view=markup) as a guideline.

Cheers,

James 

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


[jira] Assigned: (JCR-2561) SQL2 query - supplying column selector fails with NPE on getColumnName()

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

Thomas Mueller reassigned JCR-2561:
-----------------------------------

    Assignee: Thomas Mueller

> SQL2 query - supplying column selector fails with NPE on getColumnName()
> ------------------------------------------------------------------------
>
>                 Key: JCR-2561
>                 URL: https://issues.apache.org/jira/browse/JCR-2561
>             Project: Jackrabbit Content Repository
>          Issue Type: Bug
>          Components: jackrabbit-jcr-commons
>    Affects Versions: 2.0.0
>            Reporter: James Gadbury
>            Assignee: Thomas Mueller
>
> I am preparing and executing an SQL2 query (JCR 2.0) as follows:
> QueryManager qm = jcrSession.getWorkspace().getQueryManager();
> String queryString = "select order.[customerAccountUUID] as cust from [atl:order] as order";
> Query query = qm.createQuery(queryString, Query.JCR_SQL2);
> QueryResult queryResult = query.execute();
> The following query fails:
> select order.[customerAccountUUID] from [atl:order] as order
> java.lang.NullPointerException
>         org.apache.jackrabbit.commons.query.sql2.QOMFormatter.isSimpleName(QOMFormatter.java:577)
>         org.apache.jackrabbit.commons.query.sql2.QOMFormatter.formatName(QOMFormatter.java:567)
>         org.apache.jackrabbit.commons.query.sql2.QOMFormatter.format(QOMFormatter.java:452)
>         org.apache.jackrabbit.commons.query.sql2.QOMFormatter.format(QOMFormatter.java:123)
>         org.apache.jackrabbit.commons.query.sql2.QOMFormatter.format(QOMFormatter.java:117)
> line 452: c.getColumnName() returns null.
> The following query is fine:
> select order.[customerAccountUUID] as cust from [atl:order] as order
> I have been using the test case (here: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-spi-commons/src/test/resources/org/apache/jackrabbit/spi/commons/query/sql2/test.sql2.txt?view=markup) as a guideline.
> Cheers,
> James 

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


[jira] Resolved: (JCR-2561) SQL2 query - supplying column selector fails with NPE on getColumnName()

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

Thomas Mueller resolved JCR-2561.
---------------------------------

       Resolution: Fixed
    Fix Version/s: 2.0.1

> SQL2 query - supplying column selector fails with NPE on getColumnName()
> ------------------------------------------------------------------------
>
>                 Key: JCR-2561
>                 URL: https://issues.apache.org/jira/browse/JCR-2561
>             Project: Jackrabbit Content Repository
>          Issue Type: Bug
>          Components: jackrabbit-jcr-commons
>    Affects Versions: 2.0.0
>            Reporter: James Gadbury
>            Assignee: Thomas Mueller
>             Fix For: 2.0.1
>
>
> I am preparing and executing an SQL2 query (JCR 2.0) as follows:
> QueryManager qm = jcrSession.getWorkspace().getQueryManager();
> String queryString = "select order.[customerAccountUUID] as cust from [atl:order] as order";
> Query query = qm.createQuery(queryString, Query.JCR_SQL2);
> QueryResult queryResult = query.execute();
> The following query fails:
> select order.[customerAccountUUID] from [atl:order] as order
> java.lang.NullPointerException
>         org.apache.jackrabbit.commons.query.sql2.QOMFormatter.isSimpleName(QOMFormatter.java:577)
>         org.apache.jackrabbit.commons.query.sql2.QOMFormatter.formatName(QOMFormatter.java:567)
>         org.apache.jackrabbit.commons.query.sql2.QOMFormatter.format(QOMFormatter.java:452)
>         org.apache.jackrabbit.commons.query.sql2.QOMFormatter.format(QOMFormatter.java:123)
>         org.apache.jackrabbit.commons.query.sql2.QOMFormatter.format(QOMFormatter.java:117)
> line 452: c.getColumnName() returns null.
> The following query is fine:
> select order.[customerAccountUUID] as cust from [atl:order] as order
> I have been using the test case (here: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-spi-commons/src/test/resources/org/apache/jackrabbit/spi/commons/query/sql2/test.sql2.txt?view=markup) as a guideline.
> Cheers,
> James 

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


[jira] Updated: (JCR-2561) SQL2 query - supplying column selector fails with NPE on getColumnName()

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

Jukka Zitting updated JCR-2561:
-------------------------------

    Fix Version/s: 2.1.0
                       (was: 2.0.1)

> SQL2 query - supplying column selector fails with NPE on getColumnName()
> ------------------------------------------------------------------------
>
>                 Key: JCR-2561
>                 URL: https://issues.apache.org/jira/browse/JCR-2561
>             Project: Jackrabbit Content Repository
>          Issue Type: Bug
>          Components: jackrabbit-jcr-commons
>    Affects Versions: 2.0.0
>            Reporter: James Gadbury
>            Assignee: Thomas Mueller
>             Fix For: 2.1.0
>
>
> I am preparing and executing an SQL2 query (JCR 2.0) as follows:
> QueryManager qm = jcrSession.getWorkspace().getQueryManager();
> String queryString = "select order.[customerAccountUUID] as cust from [atl:order] as order";
> Query query = qm.createQuery(queryString, Query.JCR_SQL2);
> QueryResult queryResult = query.execute();
> The following query fails:
> select order.[customerAccountUUID] from [atl:order] as order
> java.lang.NullPointerException
>         org.apache.jackrabbit.commons.query.sql2.QOMFormatter.isSimpleName(QOMFormatter.java:577)
>         org.apache.jackrabbit.commons.query.sql2.QOMFormatter.formatName(QOMFormatter.java:567)
>         org.apache.jackrabbit.commons.query.sql2.QOMFormatter.format(QOMFormatter.java:452)
>         org.apache.jackrabbit.commons.query.sql2.QOMFormatter.format(QOMFormatter.java:123)
>         org.apache.jackrabbit.commons.query.sql2.QOMFormatter.format(QOMFormatter.java:117)
> line 452: c.getColumnName() returns null.
> The following query is fine:
> select order.[customerAccountUUID] as cust from [atl:order] as order
> I have been using the test case (here: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-spi-commons/src/test/resources/org/apache/jackrabbit/spi/commons/query/sql2/test.sql2.txt?view=markup) as a guideline.
> Cheers,
> James 

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira