Issue Details (XML | Word | Printable)

Key: JDO-163
Type: New Feature New Feature
Status: Resolved Resolved
Resolution: Fixed
Priority: Major Major
Assignee: Michael Watzek
Reporter: Michael Watzek
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
JDO

Implement new JDO 2 query tests cases concerning query API Extensions

Created: 04/Oct/05 09:35 PM   Updated: 11/Nov/05 11:46 PM
Return to search
Component/s: tck2
Affects Version/s: None
Fix Version/s: None

Time Tracking:
Not Specified

File Attachments:
  Size
Text File Licensed for inclusion in ASF works JDO-163.patch 2005-10-26 10:21 PM Michael Watzek 82 kB
File Licensed for inclusion in ASF works JDO-163.patch2 2005-11-04 10:27 PM Michael Watzek 84 kB
File Licensed for inclusion in ASF works JDO-163.patch3 2005-11-11 11:20 PM Michael Watzek 20 kB

Resolution Date: 09/Nov/05 02:19 AM


 Description  « Hide
We need 15 new test classes, one for each of the following assertions:

- A14.5-11: Construct a new query instance using the specified String as the single-string representation of the query.
- A14.5-12: Construct a new query instance with the given candidate class from a named query.
- A14.5-13: If the named query is not found in already-loaded metadata, the query is searched for using an algorithm. Files containing metadata are examined in turn until the query is found. The order is based on the metadata search order for class metadata, but includes files named based on the query name.
- A14.5-14: If the metadata is not found in the above, a JDOUserException is thrown.
- A14.5-15: The Query instance returned from this method can be modified by the application, just like any other Query instance.
- A14.5-16: Named queries must be compilable. Attempts to get a named query that cannot be compiled result in JDOUserException.
- A14.6-21: This method retrieves the fetch plan associated with the Query. It always returns the identical instance for the same Query instance. Any change made to the fetch plan affects subsequent query execution.
- A14.6-16: void setResult (String result); Specify the results of the query if not instances of the candidate class.
- A14.6-17: void setGrouping (String grouping); Specify the grouping of results for aggregates.
- A14.6-18: void setUnique (boolean unique); Specify that there is a single result of the query.
- A14.6-19: void setResultClass (Class resultClass); Specify the class to be used to return result instances.
- A14.6-20: setRange(int fromIncl, int toExcl); Specify the number of instances to skip over and the maximum number of result instances to return.
- A14.6-22: The Unmodifiable option, when set to true, disallows further modification of the query, except for specifying the range and result class and ignoreCache option.
- A14.6-23: The single string query is first parsed to yield the result, result class, filter, variable list, parameter list, import list, grouping, ordering, and range. Then, the values specified in APIs setResult, setResultClass, setFilter, declareVariables, declareParamters, declareImports, setGrouping, setOrdering, and setRange override the corresponding settings from the single string query.
- A14.9-1: Some JDO vendors provide extensions to the query, and these extensions must be set in the query instance prior to execution.

Details can be found on Wiki page http://wiki.apache.org/jdo/QueryTests#QueryAPIExtensions.


 All   Comments   Work Log   Change History   Subversion Commits      Sort Order: Ascending order - Click to sort in descending order
Repository Revision Date User Message
ASF #331850 Tue Nov 08 17:17:35 UTC 2005 brazil JDO-163: Implement new JDO 2 query tests cases concerning query API Extensions
Files Changed
ADD /incubator/jdo/trunk/tck20/test/java/org/apache/jdo/tck/query/api/ChangeQuery.java
ADD /incubator/jdo/trunk/tck20/test/java/org/apache/jdo/tck/query/api/MetadataSearchOrder.java
ADD /incubator/jdo/trunk/tck20/test/jdo/datastoreidentity/package.jdo
ADD /incubator/jdo/trunk/tck20/test/java/org/apache/jdo/tck/query/api/SetUnique.java
ADD /incubator/jdo/trunk/tck20/test/java/org/apache/jdo/tck/query/api/NewNamedQuery.java
ADD /incubator/jdo/trunk/tck20/test/java/org/apache/jdo/tck/query/api/SingleStringQuery.java
ADD /incubator/jdo/trunk/tck20/test/java/org/apache/jdo/tck/query/api/NamedQueryNotFound.java
ADD /incubator/jdo/trunk/tck20/test/java/org/apache/jdo/tck/query/api/SetRange.java
MODIFY /incubator/jdo/trunk/tck20/project.properties
ADD /incubator/jdo/trunk/tck20/test/jdo/applicationidentity/org/apache/jdo/tck/pc/company/Person.jdoquery
MODIFY /incubator/jdo/trunk/tck20/test/jdo/applicationidentity/org/apache/jdo/tck/pc/company/package.jdo
ADD /incubator/jdo/trunk/tck20/test/java/org/apache/jdo/tck/query/api/InvalidNamedQuery.java
ADD /incubator/jdo/trunk/tck20/test/jdo/datastoreidentity/org/apache/jdo/tck/pc/mylib/PCClass.jdo
ADD /incubator/jdo/trunk/tck20/test/java/org/apache/jdo/tck/query/api/SetGrouping.java
MODIFY /incubator/jdo/trunk/tck20/test/orm/applicationidentity/org/apache/jdo/tck/pc/company/package-derby.orm
MODIFY /incubator/jdo/trunk/tck20/test/sql/derby/datastoreidentity/schema.sql
MODIFY /incubator/jdo/trunk/tck20/test/orm/datastoreidentity/org/apache/jdo/tck/pc/mylib/package-derby.orm
ADD /incubator/jdo/trunk/tck20/test/java/org/apache/jdo/tck/query/api/QueryExtentions.java
ADD /incubator/jdo/trunk/tck20/test/jdo/applicationidentity/package.jdo
MODIFY /incubator/jdo/trunk/tck20/test/testdata/org/apache/jdo/tck/pc/mylib/mylibForQueryTests.xml
MODIFY /incubator/jdo/trunk/tck20/test/sql/derby/applicationidentity/schema.sql
ADD /incubator/jdo/trunk/tck20/test/java/org/apache/jdo/tck/query/api/NewQuerySingleString.java
MODIFY /incubator/jdo/trunk/tck20/test/java/org/apache/jdo/tck/query/QueryTest.java
ADD /incubator/jdo/trunk/tck20/test/jdo/applicationidentity/org/apache/jdo/tck/pc/mylib/PCClass.jdo
ADD /incubator/jdo/trunk/tck20/test/java/org/apache/jdo/tck/query/api/UnmodifiableQuery.java
ADD /incubator/jdo/trunk/tck20/test/java/org/apache/jdo/tck/query/api/SetResultClass.java
ADD /incubator/jdo/trunk/tck20/test/java/org/apache/jdo/tck/pc/mylib/PCClass.java
MODIFY /incubator/jdo/trunk/tck20/test/orm/applicationidentity/org/apache/jdo/tck/pc/mylib/package-derby.orm
ADD /incubator/jdo/trunk/tck20/test/jdo/datastoreidentity/org/apache/jdo/tck/pc/company/Person.jdoquery
MODIFY /incubator/jdo/trunk/tck20/test/jdo/datastoreidentity/org/apache/jdo/tck/pc/company/package.jdo
ADD /incubator/jdo/trunk/tck20/test/java/org/apache/jdo/tck/query/api/SetResult.java
MODIFY /incubator/jdo/trunk/tck20/test/java/org/apache/jdo/tck/pc/mylib/MylibReader.java
ADD /incubator/jdo/trunk/tck20/test/java/org/apache/jdo/tck/query/api/GetFetchPlan.java
MODIFY /incubator/jdo/trunk/tck20/test/orm/datastoreidentity/org/apache/jdo/tck/pc/company/package-derby.orm

Repository Revision Date User Message
ASF #332108 Wed Nov 09 19:19:56 UTC 2005 brazil JDO-163: alltests.conf was missing the new test cases.
Files Changed
MODIFY /incubator/jdo/trunk/tck20/test/conf/alltests.conf

Repository Revision Date User Message
ASF #332590 Fri Nov 11 16:23:30 UTC 2005 brazil JDO-163: Bug fixes reported by Andy on jdo-dev. Improved equals comparison for object arrays, floating points, and big devimals.
Files Changed
MODIFY /incubator/jdo/trunk/tck20/test/jdo/applicationidentity/org/apache/jdo/tck/pc/company/Person.jdoquery
MODIFY /incubator/jdo/trunk/tck20/test/java/org/apache/jdo/tck/query/api/MetadataSearchOrder.java
MODIFY /incubator/jdo/trunk/tck20/test/jdo/datastoreidentity/org/apache/jdo/tck/pc/company/Person.jdoquery
MODIFY /incubator/jdo/trunk/tck20/test/java/org/apache/jdo/tck/query/QueryTest.java
MODIFY /incubator/jdo/trunk/tck20/test/java/org/apache/jdo/tck/query/api/SingleStringQuery.java
ADD /incubator/jdo/trunk/tck20/test/java/org/apache/jdo/tck/util/ConversionHelper.java
MODIFY /incubator/jdo/trunk/tck20/maven.xml