You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@vxquery.apache.org by pr...@apache.org on 2014/04/09 00:16:27 UTC
[29/50] [abbrv] git commit: make tests location-independent - use
source elements in the catalog to identify partitions for collections - more
test resources from src/tests/resources to src/test/resources
make tests location-independent
- use source elements in the catalog to identify partitions for collections
- more test resources from src/tests/resources to src/test/resources
Project: http://git-wip-us.apache.org/repos/asf/incubator-vxquery/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-vxquery/commit/fc9c5bf1
Tree: http://git-wip-us.apache.org/repos/asf/incubator-vxquery/tree/fc9c5bf1
Diff: http://git-wip-us.apache.org/repos/asf/incubator-vxquery/diff/fc9c5bf1
Branch: refs/heads/master
Commit: fc9c5bf12943eefe72c6c778edc529b77e1be440
Parents: 16f26a6
Author: Till Westmann <we...@gmail.com>
Authored: Wed Apr 2 22:42:07 2014 -0700
Committer: Till Westmann <we...@gmail.com>
Committed: Wed Apr 2 22:42:07 2014 -0700
----------------------------------------------------------------------
.../java/org/apache/vxquery/cli/VXQuery.java | 2 +-
.../vxquery/compiler/CompilerControlBlock.java | 14 ++-
.../rewriter/rules/IntroduceCollectionRule.java | 10 +-
.../rules/SetCollectionDataSourceRule.java | 10 +-
.../metadata/VXQueryCollectionDataSource.java | 12 +-
.../metadata/VXQueryMetadataProvider.java | 20 ++-
.../xmlquery/query/XMLQueryCompiler.java | 9 +-
.../xmlquery/query/SimpleXQueryTest.java | 2 +-
.../java/org/apache/vxquery/xtest/TestCase.java | 5 +
.../apache/vxquery/xtest/TestCaseFactory.java | 10 +-
.../apache/vxquery/xtest/TestConfiguration.java | 6 +-
.../apache/vxquery/xtest/TestRunnerFactory.java | 5 +-
.../Aggregate/Partition-1/avg.txt | 1 +
.../Aggregate/Partition-1/count.txt | 1 +
.../Aggregate/Partition-1/max.txt | 1 +
.../Aggregate/Partition-1/min.txt | 1 +
.../Aggregate/Partition-1/sum.txt | 1 +
.../Aggregate/Partition-2/avg.txt | 1 +
.../Aggregate/Partition-2/count.txt | 1 +
.../Aggregate/Partition-2/max.txt | 1 +
.../Aggregate/Partition-2/min.txt | 1 +
.../Aggregate/Partition-2/sum.txt | 1 +
.../Aggregate/Partition-4/avg.txt | 1 +
.../Aggregate/Partition-4/count.txt | 1 +
.../Aggregate/Partition-4/max.txt | 1 +
.../Aggregate/Partition-4/min.txt | 1 +
.../Aggregate/Partition-4/sum.txt | 1 +
.../Ghcnd/Partition-1/q00.txt | 2 +
.../Ghcnd/Partition-1/q01.txt | 1 +
.../Ghcnd/Partition-1/q02.txt | 1 +
.../Ghcnd/Partition-1/q03.txt | 1 +
.../Ghcnd/Partition-1/q04.txt | 3 +
.../Ghcnd/Partition-1/q05.txt | 1 +
.../Ghcnd/Partition-1/q06.txt | 3 +
.../Ghcnd/Partition-1/q07.txt | 1 +
.../Ghcnd/Partition-2/q00.txt | 2 +
.../Ghcnd/Partition-2/q01.txt | 1 +
.../Ghcnd/Partition-2/q02.txt | 1 +
.../Ghcnd/Partition-2/q03.txt | 1 +
.../Ghcnd/Partition-2/q04.txt | 3 +
.../Ghcnd/Partition-2/q05.txt | 1 +
.../Ghcnd/Partition-2/q06.txt | 3 +
.../Ghcnd/Partition-2/q07.txt | 1 +
.../Ghcnd/Partition-4/q00.txt | 2 +
.../Ghcnd/Partition-4/q01.txt | 1 +
.../Ghcnd/Partition-4/q02.txt | 1 +
.../Ghcnd/Partition-4/q03.txt | 1 +
.../Ghcnd/Partition-4/q04.txt | 3 +
.../Ghcnd/Partition-4/q05.txt | 1 +
.../Ghcnd/Partition-4/q06.txt | 3 +
.../Ghcnd/Partition-4/q07.txt | 1 +
.../GhcndCount/Partition-1/q02_count.txt | 1 +
.../GhcndCount/Partition-1/q03_count.txt | 1 +
.../GhcndCount/Partition-1/q05_count.txt | 1 +
.../GhcndCount/Partition-1/q07_count.txt | 1 +
.../GhcndCount/Partition-2/q02_count.txt | 1 +
.../GhcndCount/Partition-2/q03_count.txt | 1 +
.../GhcndCount/Partition-2/q05_count.txt | 1 +
.../GhcndCount/Partition-2/q07_count.txt | 1 +
.../GhcndCount/Partition-4/q02_count.txt | 1 +
.../GhcndCount/Partition-4/q03_count.txt | 1 +
.../GhcndCount/Partition-4/q05_count.txt | 1 +
.../GhcndCount/Partition-4/q07_count.txt | 1 +
.../GhcndRecords/Partition-1/q02_records.txt | 1 +
.../GhcndRecords/Partition-1/q03_records.txt | 3 +
.../GhcndRecords/Partition-1/q05_records.txt | 1 +
.../GhcndRecords/Partition-1/q07_records.txt | 3 +
.../GhcndRecords/Partition-2/q02_records.txt | 1 +
.../GhcndRecords/Partition-2/q03_records.txt | 3 +
.../GhcndRecords/Partition-2/q05_records.txt | 1 +
.../GhcndRecords/Partition-2/q07_records.txt | 3 +
.../GhcndRecords/Partition-4/q02_records.txt | 1 +
.../GhcndRecords/Partition-4/q03_records.txt | 3 +
.../GhcndRecords/Partition-4/q05_records.txt | 1 +
.../GhcndRecords/Partition-4/q07_records.txt | 3 +
.../Queries/XQuery/Aggregate/Partition-1/avg.xq | 8 ++
.../XQuery/Aggregate/Partition-1/count.xq | 8 ++
.../Queries/XQuery/Aggregate/Partition-1/max.xq | 8 ++
.../Queries/XQuery/Aggregate/Partition-1/min.xq | 8 ++
.../Queries/XQuery/Aggregate/Partition-1/sum.xq | 8 ++
.../Queries/XQuery/Aggregate/Partition-2/avg.xq | 8 ++
.../XQuery/Aggregate/Partition-2/count.xq | 8 ++
.../Queries/XQuery/Aggregate/Partition-2/max.xq | 8 ++
.../Queries/XQuery/Aggregate/Partition-2/min.xq | 8 ++
.../Queries/XQuery/Aggregate/Partition-2/sum.xq | 8 ++
.../Queries/XQuery/Aggregate/Partition-4/avg.xq | 8 ++
.../XQuery/Aggregate/Partition-4/count.xq | 8 ++
.../Queries/XQuery/Aggregate/Partition-4/max.xq | 8 ++
.../Queries/XQuery/Aggregate/Partition-4/min.xq | 8 ++
.../Queries/XQuery/Aggregate/Partition-4/sum.xq | 8 ++
.../Queries/XQuery/Ghcnd/Partition-1/q00.xq | 11 ++
.../Queries/XQuery/Ghcnd/Partition-1/q01.xq | 8 ++
.../Queries/XQuery/Ghcnd/Partition-1/q02.xq | 11 ++
.../Queries/XQuery/Ghcnd/Partition-1/q03.xq | 8 ++
.../Queries/XQuery/Ghcnd/Partition-1/q04.xq | 13 ++
.../XQuery/Ghcnd/Partition-1/q04_sensors.xq | 8 ++
.../XQuery/Ghcnd/Partition-1/q04_stations.xq | 8 ++
.../Queries/XQuery/Ghcnd/Partition-1/q05.xq | 16 +++
.../Queries/XQuery/Ghcnd/Partition-1/q06.xq | 13 ++
.../Queries/XQuery/Ghcnd/Partition-1/q07.xq | 16 +++
.../Queries/XQuery/Ghcnd/Partition-2/q00.xq | 11 ++
.../Queries/XQuery/Ghcnd/Partition-2/q01.xq | 8 ++
.../Queries/XQuery/Ghcnd/Partition-2/q02.xq | 11 ++
.../Queries/XQuery/Ghcnd/Partition-2/q03.xq | 8 ++
.../Queries/XQuery/Ghcnd/Partition-2/q04.xq | 13 ++
.../Queries/XQuery/Ghcnd/Partition-2/q05.xq | 16 +++
.../Queries/XQuery/Ghcnd/Partition-2/q06.xq | 13 ++
.../Queries/XQuery/Ghcnd/Partition-2/q07.xq | 16 +++
.../Queries/XQuery/Ghcnd/Partition-4/q00.xq | 11 ++
.../Queries/XQuery/Ghcnd/Partition-4/q01.xq | 8 ++
.../Queries/XQuery/Ghcnd/Partition-4/q02.xq | 11 ++
.../Queries/XQuery/Ghcnd/Partition-4/q03.xq | 8 ++
.../Queries/XQuery/Ghcnd/Partition-4/q04.xq | 13 ++
.../Queries/XQuery/Ghcnd/Partition-4/q05.xq | 16 +++
.../Queries/XQuery/Ghcnd/Partition-4/q06.xq | 13 ++
.../Queries/XQuery/Ghcnd/Partition-4/q07.xq | 16 +++
.../XQuery/GhcndCount/Partition-1/q02_count.xq | 11 ++
.../XQuery/GhcndCount/Partition-1/q03_count.xq | 8 ++
.../XQuery/GhcndCount/Partition-1/q05_count.xq | 16 +++
.../XQuery/GhcndCount/Partition-1/q07_count.xq | 16 +++
.../XQuery/GhcndCount/Partition-2/q02_count.xq | 11 ++
.../XQuery/GhcndCount/Partition-2/q03_count.xq | 8 ++
.../XQuery/GhcndCount/Partition-2/q05_count.xq | 16 +++
.../XQuery/GhcndCount/Partition-2/q07_count.xq | 16 +++
.../XQuery/GhcndCount/Partition-4/q02_count.xq | 11 ++
.../XQuery/GhcndCount/Partition-4/q03_count.xq | 8 ++
.../XQuery/GhcndCount/Partition-4/q05_count.xq | 16 +++
.../XQuery/GhcndCount/Partition-4/q07_count.xq | 16 +++
.../GhcndRecords/Partition-1/q02_records.xq | 9 ++
.../GhcndRecords/Partition-1/q03_records.xq | 6 +
.../GhcndRecords/Partition-1/q05_records.xq | 14 +++
.../GhcndRecords/Partition-1/q07_records.xq | 14 +++
.../GhcndRecords/Partition-2/q02_records.xq | 9 ++
.../GhcndRecords/Partition-2/q03_records.xq | 6 +
.../GhcndRecords/Partition-2/q05_records.xq | 14 +++
.../GhcndRecords/Partition-2/q07_records.xq | 14 +++
.../GhcndRecords/Partition-4/q02_records.xq | 9 ++
.../GhcndRecords/Partition-4/q03_records.xq | 6 +
.../GhcndRecords/Partition-4/q05_records.xq | 14 +++
.../GhcndRecords/Partition-4/q07_records.xq | 14 +++
.../quarter_1/sesnors/US000000001_200101_0.xml | 1 +
.../half_1/quarter_1/stations/US000000001.xml | 1 +
.../quarter_2/sesnors/US000000002_200202_0.xml | 1 +
.../half_1/quarter_2/stations/US000000004.xml | 1 +
.../quarter_3/sesnors/AS000000003_200303_0.xml | 1 +
.../half_2/quarter_3/stations/US000000002.xml | 1 +
.../quarter_4/sesnors/US000000004_200404_0.xml | 1 +
.../half_2/quarter_4/stations/AS000000003.xml | 1 +
.../src/test/resources/VXQueryCatalog.xml | 124 +++++++++++++++++++
.../cat/AggregatePartition1Queries.xml | 31 +++++
.../cat/AggregatePartition2Queries.xml | 36 ++++++
.../cat/AggregatePartition4Queries.xml | 36 ++++++
.../cat/GhcndCountPartition1Queries.xml | 30 +++++
.../cat/GhcndCountPartition2Queries.xml | 30 +++++
.../cat/GhcndCountPartition4Queries.xml | 30 +++++
.../resources/cat/GhcndPartition1Queries.xml | 54 ++++++++
.../resources/cat/GhcndPartition2Queries.xml | 54 ++++++++
.../resources/cat/GhcndPartition4Queries.xml | 54 ++++++++
.../cat/GhcndRecordsPartition1Queries.xml | 30 +++++
.../cat/GhcndRecordsPartition2Queries.xml | 30 +++++
.../cat/GhcndRecordsPartition4Queries.xml | 30 +++++
.../Aggregate/Partition-1/avg.txt | 1 -
.../Aggregate/Partition-1/count.txt | 1 -
.../Aggregate/Partition-1/max.txt | 1 -
.../Aggregate/Partition-1/min.txt | 1 -
.../Aggregate/Partition-1/sum.txt | 1 -
.../Aggregate/Partition-2/avg.txt | 1 -
.../Aggregate/Partition-2/count.txt | 1 -
.../Aggregate/Partition-2/max.txt | 1 -
.../Aggregate/Partition-2/min.txt | 1 -
.../Aggregate/Partition-2/sum.txt | 1 -
.../Aggregate/Partition-4/avg.txt | 1 -
.../Aggregate/Partition-4/count.txt | 1 -
.../Aggregate/Partition-4/max.txt | 1 -
.../Aggregate/Partition-4/min.txt | 1 -
.../Aggregate/Partition-4/sum.txt | 1 -
.../Ghcnd/Partition-1/q00.txt | 2 -
.../Ghcnd/Partition-1/q01.txt | 1 -
.../Ghcnd/Partition-1/q02.txt | 1 -
.../Ghcnd/Partition-1/q03.txt | 1 -
.../Ghcnd/Partition-1/q04.txt | 3 -
.../Ghcnd/Partition-1/q05.txt | 1 -
.../Ghcnd/Partition-1/q06.txt | 3 -
.../Ghcnd/Partition-1/q07.txt | 1 -
.../Ghcnd/Partition-2/q00.txt | 2 -
.../Ghcnd/Partition-2/q01.txt | 1 -
.../Ghcnd/Partition-2/q02.txt | 1 -
.../Ghcnd/Partition-2/q03.txt | 1 -
.../Ghcnd/Partition-2/q04.txt | 3 -
.../Ghcnd/Partition-2/q05.txt | 1 -
.../Ghcnd/Partition-2/q06.txt | 3 -
.../Ghcnd/Partition-2/q07.txt | 1 -
.../Ghcnd/Partition-4/q00.txt | 2 -
.../Ghcnd/Partition-4/q01.txt | 1 -
.../Ghcnd/Partition-4/q02.txt | 1 -
.../Ghcnd/Partition-4/q03.txt | 1 -
.../Ghcnd/Partition-4/q04.txt | 3 -
.../Ghcnd/Partition-4/q05.txt | 1 -
.../Ghcnd/Partition-4/q06.txt | 3 -
.../Ghcnd/Partition-4/q07.txt | 1 -
.../GhcndCount/Partition-1/q02_count.txt | 1 -
.../GhcndCount/Partition-1/q03_count.txt | 1 -
.../GhcndCount/Partition-1/q05_count.txt | 1 -
.../GhcndCount/Partition-1/q07_count.txt | 1 -
.../GhcndCount/Partition-2/q02_count.txt | 1 -
.../GhcndCount/Partition-2/q03_count.txt | 1 -
.../GhcndCount/Partition-2/q05_count.txt | 1 -
.../GhcndCount/Partition-2/q07_count.txt | 1 -
.../GhcndCount/Partition-4/q02_count.txt | 1 -
.../GhcndCount/Partition-4/q03_count.txt | 1 -
.../GhcndCount/Partition-4/q05_count.txt | 1 -
.../GhcndCount/Partition-4/q07_count.txt | 1 -
.../GhcndRecords/Partition-1/q02_records.txt | 1 -
.../GhcndRecords/Partition-1/q03_records.txt | 3 -
.../GhcndRecords/Partition-1/q05_records.txt | 1 -
.../GhcndRecords/Partition-1/q07_records.txt | 3 -
.../GhcndRecords/Partition-2/q02_records.txt | 1 -
.../GhcndRecords/Partition-2/q03_records.txt | 3 -
.../GhcndRecords/Partition-2/q05_records.txt | 1 -
.../GhcndRecords/Partition-2/q07_records.txt | 3 -
.../GhcndRecords/Partition-4/q02_records.txt | 1 -
.../GhcndRecords/Partition-4/q03_records.txt | 3 -
.../GhcndRecords/Partition-4/q05_records.txt | 1 -
.../GhcndRecords/Partition-4/q07_records.txt | 3 -
.../Queries/XQuery/Aggregate/Partition-1/avg.xq | 8 --
.../XQuery/Aggregate/Partition-1/count.xq | 8 --
.../Queries/XQuery/Aggregate/Partition-1/max.xq | 8 --
.../Queries/XQuery/Aggregate/Partition-1/min.xq | 8 --
.../Queries/XQuery/Aggregate/Partition-1/sum.xq | 8 --
.../Queries/XQuery/Aggregate/Partition-2/avg.xq | 8 --
.../XQuery/Aggregate/Partition-2/count.xq | 8 --
.../Queries/XQuery/Aggregate/Partition-2/max.xq | 8 --
.../Queries/XQuery/Aggregate/Partition-2/min.xq | 8 --
.../Queries/XQuery/Aggregate/Partition-2/sum.xq | 8 --
.../Queries/XQuery/Aggregate/Partition-4/avg.xq | 8 --
.../XQuery/Aggregate/Partition-4/count.xq | 8 --
.../Queries/XQuery/Aggregate/Partition-4/max.xq | 8 --
.../Queries/XQuery/Aggregate/Partition-4/min.xq | 8 --
.../Queries/XQuery/Aggregate/Partition-4/sum.xq | 8 --
.../Queries/XQuery/Ghcnd/Partition-1/q00.xq | 11 --
.../Queries/XQuery/Ghcnd/Partition-1/q01.xq | 8 --
.../Queries/XQuery/Ghcnd/Partition-1/q02.xq | 11 --
.../Queries/XQuery/Ghcnd/Partition-1/q03.xq | 8 --
.../Queries/XQuery/Ghcnd/Partition-1/q04.xq | 13 --
.../XQuery/Ghcnd/Partition-1/q04_sensors.xq | 8 --
.../XQuery/Ghcnd/Partition-1/q04_stations.xq | 8 --
.../Queries/XQuery/Ghcnd/Partition-1/q05.xq | 16 ---
.../Queries/XQuery/Ghcnd/Partition-1/q06.xq | 13 --
.../Queries/XQuery/Ghcnd/Partition-1/q07.xq | 16 ---
.../Queries/XQuery/Ghcnd/Partition-2/q00.xq | 11 --
.../Queries/XQuery/Ghcnd/Partition-2/q01.xq | 8 --
.../Queries/XQuery/Ghcnd/Partition-2/q02.xq | 11 --
.../Queries/XQuery/Ghcnd/Partition-2/q03.xq | 8 --
.../Queries/XQuery/Ghcnd/Partition-2/q04.xq | 13 --
.../Queries/XQuery/Ghcnd/Partition-2/q05.xq | 16 ---
.../Queries/XQuery/Ghcnd/Partition-2/q06.xq | 13 --
.../Queries/XQuery/Ghcnd/Partition-2/q07.xq | 16 ---
.../Queries/XQuery/Ghcnd/Partition-4/q00.xq | 11 --
.../Queries/XQuery/Ghcnd/Partition-4/q01.xq | 8 --
.../Queries/XQuery/Ghcnd/Partition-4/q02.xq | 11 --
.../Queries/XQuery/Ghcnd/Partition-4/q03.xq | 8 --
.../Queries/XQuery/Ghcnd/Partition-4/q04.xq | 13 --
.../Queries/XQuery/Ghcnd/Partition-4/q05.xq | 16 ---
.../Queries/XQuery/Ghcnd/Partition-4/q06.xq | 13 --
.../Queries/XQuery/Ghcnd/Partition-4/q07.xq | 16 ---
.../XQuery/GhcndCount/Partition-1/q02_count.xq | 11 --
.../XQuery/GhcndCount/Partition-1/q03_count.xq | 8 --
.../XQuery/GhcndCount/Partition-1/q05_count.xq | 16 ---
.../XQuery/GhcndCount/Partition-1/q07_count.xq | 16 ---
.../XQuery/GhcndCount/Partition-2/q02_count.xq | 11 --
.../XQuery/GhcndCount/Partition-2/q03_count.xq | 8 --
.../XQuery/GhcndCount/Partition-2/q05_count.xq | 16 ---
.../XQuery/GhcndCount/Partition-2/q07_count.xq | 16 ---
.../XQuery/GhcndCount/Partition-4/q02_count.xq | 11 --
.../XQuery/GhcndCount/Partition-4/q03_count.xq | 8 --
.../XQuery/GhcndCount/Partition-4/q05_count.xq | 16 ---
.../XQuery/GhcndCount/Partition-4/q07_count.xq | 16 ---
.../GhcndRecords/Partition-1/q02_records.xq | 9 --
.../GhcndRecords/Partition-1/q03_records.xq | 6 -
.../GhcndRecords/Partition-1/q05_records.xq | 14 ---
.../GhcndRecords/Partition-1/q07_records.xq | 14 ---
.../GhcndRecords/Partition-2/q02_records.xq | 9 --
.../GhcndRecords/Partition-2/q03_records.xq | 6 -
.../GhcndRecords/Partition-2/q05_records.xq | 14 ---
.../GhcndRecords/Partition-2/q07_records.xq | 14 ---
.../GhcndRecords/Partition-4/q02_records.xq | 9 --
.../GhcndRecords/Partition-4/q03_records.xq | 6 -
.../GhcndRecords/Partition-4/q05_records.xq | 14 ---
.../GhcndRecords/Partition-4/q07_records.xq | 14 ---
.../quarter_1/sesnors/US000000001_200101_0.xml | 1 -
.../half_1/quarter_1/stations/US000000001.xml | 1 -
.../quarter_2/sesnors/US000000002_200202_0.xml | 1 -
.../half_1/quarter_2/stations/US000000004.xml | 1 -
.../quarter_3/sesnors/AS000000003_200303_0.xml | 1 -
.../half_2/quarter_3/stations/US000000002.xml | 1 -
.../quarter_4/sesnors/US000000004_200404_0.xml | 1 -
.../half_2/quarter_4/stations/AS000000003.xml | 1 -
.../src/tests/resources/VXQueryCatalog.xml | 98 ---------------
.../cat/AggregatePartition1Queries.xml | 31 -----
.../cat/AggregatePartition2Queries.xml | 36 ------
.../cat/AggregatePartition4Queries.xml | 36 ------
.../cat/GhcndCountPartition1Queries.xml | 30 -----
.../cat/GhcndCountPartition2Queries.xml | 30 -----
.../cat/GhcndCountPartition4Queries.xml | 30 -----
.../resources/cat/GhcndPartition1Queries.xml | 54 --------
.../resources/cat/GhcndPartition2Queries.xml | 54 --------
.../resources/cat/GhcndPartition4Queries.xml | 54 --------
.../cat/GhcndRecordsPartition1Queries.xml | 30 -----
.../cat/GhcndRecordsPartition2Queries.xml | 30 -----
.../cat/GhcndRecordsPartition4Queries.xml | 30 -----
310 files changed, 1441 insertions(+), 1384 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-cli/src/main/java/org/apache/vxquery/cli/VXQuery.java
----------------------------------------------------------------------
diff --git a/vxquery-cli/src/main/java/org/apache/vxquery/cli/VXQuery.java b/vxquery-cli/src/main/java/org/apache/vxquery/cli/VXQuery.java
index ada055d..13853f7 100644
--- a/vxquery-cli/src/main/java/org/apache/vxquery/cli/VXQuery.java
+++ b/vxquery-cli/src/main/java/org/apache/vxquery/cli/VXQuery.java
@@ -256,7 +256,7 @@ public class VXQuery {
XMLQueryCompiler compiler = new XMLQueryCompiler(listener, getNodeList(), opts.frameSize);
resultSetId = createResultSetId();
CompilerControlBlock ccb = new CompilerControlBlock(new StaticContextImpl(RootStaticContextImpl.INSTANCE),
- resultSetId);
+ resultSetId, null);
compiler.compile(query, new StringReader(qStr), ccb, opts.optimizationLevel);
// if -timing argument passed, show the starting and ending times
if (opts.timing) {
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-core/src/main/java/org/apache/vxquery/compiler/CompilerControlBlock.java
----------------------------------------------------------------------
diff --git a/vxquery-core/src/main/java/org/apache/vxquery/compiler/CompilerControlBlock.java b/vxquery-core/src/main/java/org/apache/vxquery/compiler/CompilerControlBlock.java
index a737a92..ab58442 100644
--- a/vxquery-core/src/main/java/org/apache/vxquery/compiler/CompilerControlBlock.java
+++ b/vxquery-core/src/main/java/org/apache/vxquery/compiler/CompilerControlBlock.java
@@ -16,6 +16,9 @@
*/
package org.apache.vxquery.compiler;
+import java.io.File;
+import java.util.Map;
+
import org.apache.vxquery.context.StaticContext;
import edu.uci.ics.hyracks.api.dataset.ResultSetId;
@@ -25,9 +28,12 @@ public class CompilerControlBlock {
private ResultSetId resultSetId;
- public CompilerControlBlock(StaticContext ctx, ResultSetId resultSetId) {
+ private Map<String, File> sourceFileMap;
+
+ public CompilerControlBlock(StaticContext ctx, ResultSetId resultSetId, Map<String, File> sourceFileMap) {
this.ctx = ctx;
this.resultSetId = resultSetId;
+ this.sourceFileMap = sourceFileMap;
}
public StaticContext getStaticContext() {
@@ -37,4 +43,8 @@ public class CompilerControlBlock {
public ResultSetId getResultSetId() {
return resultSetId;
}
-}
\ No newline at end of file
+
+ public Map<String, File> getSourceFileMap() {
+ return sourceFileMap;
+ }
+}
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-core/src/main/java/org/apache/vxquery/compiler/rewriter/rules/IntroduceCollectionRule.java
----------------------------------------------------------------------
diff --git a/vxquery-core/src/main/java/org/apache/vxquery/compiler/rewriter/rules/IntroduceCollectionRule.java b/vxquery-core/src/main/java/org/apache/vxquery/compiler/rewriter/rules/IntroduceCollectionRule.java
index bc8d58a..a5cdfe7 100644
--- a/vxquery-core/src/main/java/org/apache/vxquery/compiler/rewriter/rules/IntroduceCollectionRule.java
+++ b/vxquery-core/src/main/java/org/apache/vxquery/compiler/rewriter/rules/IntroduceCollectionRule.java
@@ -16,9 +16,6 @@
*/
package org.apache.vxquery.compiler.rewriter.rules;
-import java.util.ArrayList;
-import java.util.List;
-
import org.apache.commons.lang3.mutable.Mutable;
import org.apache.vxquery.compiler.rewriter.VXQueryOptimizationContext;
import org.apache.vxquery.metadata.VXQueryCollectionDataSource;
@@ -76,11 +73,8 @@ public class IntroduceCollectionRule extends AbstractCollectionRule {
if (collectionName != null) {
// Build the new operator and update the query plan.
int collectionId = vxqueryContext.newCollectionId();
- List<Object> types = new ArrayList<Object>();
- types.add(SequenceType.create(AnyItemType.INSTANCE, Quantifier.QUANT_STAR));
-
- VXQueryCollectionDataSource ds = new VXQueryCollectionDataSource(collectionId, collectionName,
- types.toArray());
+ VXQueryCollectionDataSource ds = VXQueryCollectionDataSource.create(collectionId, collectionName,
+ SequenceType.create(AnyItemType.INSTANCE, Quantifier.QUANT_STAR));
if (ds != null) {
ds.setTotalDataSources(vxqueryContext.getTotalDataSources());
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-core/src/main/java/org/apache/vxquery/compiler/rewriter/rules/SetCollectionDataSourceRule.java
----------------------------------------------------------------------
diff --git a/vxquery-core/src/main/java/org/apache/vxquery/compiler/rewriter/rules/SetCollectionDataSourceRule.java b/vxquery-core/src/main/java/org/apache/vxquery/compiler/rewriter/rules/SetCollectionDataSourceRule.java
index 1d81a8c..2ddee4d 100644
--- a/vxquery-core/src/main/java/org/apache/vxquery/compiler/rewriter/rules/SetCollectionDataSourceRule.java
+++ b/vxquery-core/src/main/java/org/apache/vxquery/compiler/rewriter/rules/SetCollectionDataSourceRule.java
@@ -16,9 +16,6 @@
*/
package org.apache.vxquery.compiler.rewriter.rules;
-import java.util.ArrayList;
-import java.util.List;
-
import org.apache.commons.lang3.mutable.Mutable;
import org.apache.vxquery.compiler.rewriter.VXQueryOptimizationContext;
import org.apache.vxquery.metadata.VXQueryCollectionDataSource;
@@ -46,11 +43,8 @@ public class SetCollectionDataSourceRule extends AbstractCollectionRule {
// Build the new collection.
if (collectionName != null && vxqueryContext.getCollectionDataSourceMap(collectionName) == null) {
int collectionId = vxqueryContext.getCollectionDataSourceMapSize() + 1;
- List<Object> types = new ArrayList<Object>();
- types.add(SequenceType.create(AnyItemType.INSTANCE, Quantifier.QUANT_STAR));
-
- VXQueryCollectionDataSource ds = new VXQueryCollectionDataSource(collectionId, collectionName,
- types.toArray());
+ VXQueryCollectionDataSource ds = VXQueryCollectionDataSource.create(collectionId, collectionName,
+ SequenceType.create(AnyItemType.INSTANCE, Quantifier.QUANT_STAR));
vxqueryContext.putCollectionDataSourceMap(collectionName, ds);
context.addToDontApplySet(this, opRef.getValue());
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-core/src/main/java/org/apache/vxquery/metadata/VXQueryCollectionDataSource.java
----------------------------------------------------------------------
diff --git a/vxquery-core/src/main/java/org/apache/vxquery/metadata/VXQueryCollectionDataSource.java b/vxquery-core/src/main/java/org/apache/vxquery/metadata/VXQueryCollectionDataSource.java
index e48d4ab..5c2867f 100644
--- a/vxquery-core/src/main/java/org/apache/vxquery/metadata/VXQueryCollectionDataSource.java
+++ b/vxquery-core/src/main/java/org/apache/vxquery/metadata/VXQueryCollectionDataSource.java
@@ -34,7 +34,7 @@ public class VXQueryCollectionDataSource implements IDataSource<String> {
private static final String DELIMITER = "\\|";
private final int dataSourceId;
private final String collectionName;
- private final String[] collectionPartitions;
+ private String[] collectionPartitions;
private final List<Integer> childSeq;
private int totalDataSources;
@@ -42,7 +42,11 @@ public class VXQueryCollectionDataSource implements IDataSource<String> {
private IDataSourcePropertiesProvider propProvider;
- public VXQueryCollectionDataSource(int id, String file, Object[] types) {
+ public static VXQueryCollectionDataSource create(int id, String file, Object type) {
+ return new VXQueryCollectionDataSource(id, file, new Object[] { type });
+ }
+
+ private VXQueryCollectionDataSource(int id, String file, Object[] types) {
this.dataSourceId = id;
this.collectionName = file;
collectionPartitions = collectionName.split(DELIMITER);
@@ -74,6 +78,10 @@ public class VXQueryCollectionDataSource implements IDataSource<String> {
return collectionPartitions;
}
+ public void setPartitions(String[] collectionPartitions) {
+ this.collectionPartitions = collectionPartitions;
+ }
+
public int getPartitionCount() {
return collectionPartitions.length;
}
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-core/src/main/java/org/apache/vxquery/metadata/VXQueryMetadataProvider.java
----------------------------------------------------------------------
diff --git a/vxquery-core/src/main/java/org/apache/vxquery/metadata/VXQueryMetadataProvider.java b/vxquery-core/src/main/java/org/apache/vxquery/metadata/VXQueryMetadataProvider.java
index 0aaac5c..678b74a 100644
--- a/vxquery-core/src/main/java/org/apache/vxquery/metadata/VXQueryMetadataProvider.java
+++ b/vxquery-core/src/main/java/org/apache/vxquery/metadata/VXQueryMetadataProvider.java
@@ -16,9 +16,13 @@
*/
package org.apache.vxquery.metadata;
+import java.io.File;
import java.io.IOException;
import java.util.ArrayList;
import java.util.List;
+import java.util.Map;
+
+import javax.xml.namespace.QName;
import edu.uci.ics.hyracks.algebricks.common.constraints.AlgebricksAbsolutePartitionConstraint;
import edu.uci.ics.hyracks.algebricks.common.constraints.AlgebricksPartitionConstraint;
@@ -51,9 +55,11 @@ import edu.uci.ics.hyracks.dataflow.std.result.ResultWriterOperatorDescriptor;
public class VXQueryMetadataProvider implements IMetadataProvider<String, String> {
String[] nodeList;
+ Map<String, File> sourceFileMap;
- public VXQueryMetadataProvider(String[] nodeList) {
+ public VXQueryMetadataProvider(String[] nodeList, Map<String, File> sourceFileMap) {
this.nodeList = nodeList;
+ this.sourceFileMap = sourceFileMap;
}
@Override
@@ -67,6 +73,16 @@ public class VXQueryMetadataProvider implements IMetadataProvider<String, String
IOperatorSchema opSchema, IVariableTypeEnvironment typeEnv, JobGenContext context,
JobSpecification jobSpec, Object implConfig) throws AlgebricksException {
VXQueryCollectionDataSource ds = (VXQueryCollectionDataSource) dataSource;
+ if (sourceFileMap != null) {
+ final int len = ds.getPartitions().length;
+ String[] collectionPartitions = new String[len];
+ for (int i = 0; i < len; ++i) {
+ String partition = ds.getPartitions()[i];
+ File mapped = sourceFileMap.get(partition);
+ collectionPartitions[i] = mapped != null ? mapped.toString() : partition;
+ }
+ ds.setPartitions(collectionPartitions);
+ }
RecordDescriptor rDesc = new RecordDescriptor(new ISerializerDeserializer[opSchema.getSize()]);
IOperatorDescriptor scanner = new VXQueryCollectionOperatorDescriptor(jobSpec, ds, rDesc);
@@ -74,7 +90,7 @@ public class VXQueryMetadataProvider implements IMetadataProvider<String, String
return new Pair<IOperatorDescriptor, AlgebricksPartitionConstraint>(scanner, constraint);
}
- public AlgebricksPartitionConstraint getClusterLocations() {
+ public static AlgebricksPartitionConstraint getClusterLocations(String[] nodeList) {
int availableProcessors = Runtime.getRuntime().availableProcessors();
if (availableProcessors < 1) {
availableProcessors = 1;
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-core/src/main/java/org/apache/vxquery/xmlquery/query/XMLQueryCompiler.java
----------------------------------------------------------------------
diff --git a/vxquery-core/src/main/java/org/apache/vxquery/xmlquery/query/XMLQueryCompiler.java b/vxquery-core/src/main/java/org/apache/vxquery/xmlquery/query/XMLQueryCompiler.java
index d07de9a..0c8ff90 100644
--- a/vxquery-core/src/main/java/org/apache/vxquery/xmlquery/query/XMLQueryCompiler.java
+++ b/vxquery-core/src/main/java/org/apache/vxquery/xmlquery/query/XMLQueryCompiler.java
@@ -79,8 +79,6 @@ public class XMLQueryCompiler {
private final ICompilerFactory cFactory;
- private final VXQueryMetadataProvider mdProvider;
-
private LogicalOperatorPrettyPrintVisitor pprinter;
private ModuleNode moduleNode;
@@ -91,9 +89,12 @@ public class XMLQueryCompiler {
private int frameSize;
+ private String[] nodeList;
+
public XMLQueryCompiler(XQueryCompilationListener listener, String[] nodeList, int frameSize) {
this.listener = listener == null ? NoopXQueryCompilationListener.INSTANCE : listener;
this.frameSize = frameSize;
+ this.nodeList = nodeList;
HeuristicCompilerFactoryBuilder builder = new HeuristicCompilerFactoryBuilder(
new IOptimizationContextFactory() {
@Override
@@ -147,8 +148,7 @@ public class XMLQueryCompiler {
}
});
builder.setNullWriterFactory(new VXQueryNullWriterFactory());
- mdProvider = new VXQueryMetadataProvider(nodeList);
- builder.setClusterLocations(mdProvider.getClusterLocations());
+ builder.setClusterLocations(VXQueryMetadataProvider.getClusterLocations(nodeList));
cFactory = builder.create();
}
@@ -159,6 +159,7 @@ public class XMLQueryCompiler {
module = new XMLQueryTranslator(ccb).translateModule(moduleNode);
pprinter = new LogicalOperatorPrettyPrintVisitor(new VXQueryLogicalExpressionPrettyPrintVisitor(module
.getModuleContext()));
+ VXQueryMetadataProvider mdProvider = new VXQueryMetadataProvider(nodeList, ccb.getSourceFileMap());
compiler = cFactory.createCompiler(module.getBody(), mdProvider, 0);
listener.notifyTranslationResult(module);
XMLQueryTypeChecker.typeCheckModule(module);
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-core/src/test/java/org/apache/vxquery/xmlquery/query/SimpleXQueryTest.java
----------------------------------------------------------------------
diff --git a/vxquery-core/src/test/java/org/apache/vxquery/xmlquery/query/SimpleXQueryTest.java b/vxquery-core/src/test/java/org/apache/vxquery/xmlquery/query/SimpleXQueryTest.java
index 82d9635..37b529b 100644
--- a/vxquery-core/src/test/java/org/apache/vxquery/xmlquery/query/SimpleXQueryTest.java
+++ b/vxquery-core/src/test/java/org/apache/vxquery/xmlquery/query/SimpleXQueryTest.java
@@ -135,7 +135,7 @@ public class SimpleXQueryTest {
private static void runTestInternal(String testName, String query) throws Exception {
XMLQueryCompiler compiler = new XMLQueryCompiler(null, new String[] { "nc1" }, 65536);
CompilerControlBlock ccb = new CompilerControlBlock(new StaticContextImpl(RootStaticContextImpl.INSTANCE),
- new ResultSetId(System.nanoTime()));
+ new ResultSetId(System.nanoTime()), null);
compiler.compile(testName, new StringReader(query), ccb, Integer.MAX_VALUE);
}
}
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/main/java/org/apache/vxquery/xtest/TestCase.java
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/main/java/org/apache/vxquery/xtest/TestCase.java b/vxquery-xtest/src/main/java/org/apache/vxquery/xtest/TestCase.java
index 63d330c..fbfc566 100644
--- a/vxquery-xtest/src/main/java/org/apache/vxquery/xtest/TestCase.java
+++ b/vxquery-xtest/src/main/java/org/apache/vxquery/xtest/TestCase.java
@@ -19,6 +19,7 @@ package org.apache.vxquery.xtest;
import java.io.File;
import java.io.IOException;
import java.util.ArrayList;
+import java.util.Collections;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
@@ -75,6 +76,10 @@ public class TestCase {
return extVars.get(varName);
}
+ public Map<String, File> getSourceFileMap() {
+ return Collections.unmodifiableMap(tConfig.sourceFileMap);
+ }
+
public void setExpectedError(String error) {
this.expectedError = error;
}
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/main/java/org/apache/vxquery/xtest/TestCaseFactory.java
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/main/java/org/apache/vxquery/xtest/TestCaseFactory.java b/vxquery-xtest/src/main/java/org/apache/vxquery/xtest/TestCaseFactory.java
index c39f0d2..cadd5a7 100644
--- a/vxquery-xtest/src/main/java/org/apache/vxquery/xtest/TestCaseFactory.java
+++ b/vxquery-xtest/src/main/java/org/apache/vxquery/xtest/TestCaseFactory.java
@@ -18,8 +18,6 @@ import java.io.File;
import java.io.FileReader;
import java.io.IOException;
import java.net.URL;
-import java.util.HashMap;
-import java.util.Map;
import java.util.concurrent.ExecutorService;
import java.util.regex.Pattern;
@@ -36,7 +34,6 @@ import org.xml.sax.helpers.XMLReaderFactory;
public class TestCaseFactory {
private TestConfiguration tConfig;
- private Map<String, File> srcMap;
private File catalog;
private String baseDirectory;
private TestRunnerFactory trf;
@@ -66,7 +63,6 @@ public class TestCaseFactory {
if (opts.exclude != null) {
this.exclude = Pattern.compile(opts.exclude);
}
- srcMap = new HashMap<String, File>();
try {
currPathLen = new File(".").getCanonicalPath().length();
} catch (IOException e) {
@@ -121,11 +117,11 @@ public class TestCaseFactory {
String str = buffer.toString();
buffer = null;
if (nextVariable != null) {
- if (srcMap.get(str) == null) {
+ if (tConfig.sourceFileMap.get(str) == null) {
System.err.println(tc.getXQueryFile());
System.err.println(str);
}
- tc.addExternalVariableBinding(new QName(nextVariable), srcMap.get(str));
+ tc.addExternalVariableBinding(new QName(nextVariable), tConfig.sourceFileMap.get(str));
} else if (expectedError) {
tc.setExpectedError(str);
} else if (outputFile) {
@@ -208,7 +204,7 @@ public class TestCaseFactory {
} else if ("source".equals(localName)) {
String id = atts.getValue("", "ID");
File srcFile = new File(tConfig.testRoot, atts.getValue("", "FileName"));
- srcMap.put(id, srcFile);
+ tConfig.sourceFileMap.put(id, srcFile);
} else if ("test-suite".equals(localName)) {
tConfig.testRoot = new File(new File(baseDirectory).getCanonicalFile(), atts.getValue("",
"SourceOffsetPath"));
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/main/java/org/apache/vxquery/xtest/TestConfiguration.java
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/main/java/org/apache/vxquery/xtest/TestConfiguration.java b/vxquery-xtest/src/main/java/org/apache/vxquery/xtest/TestConfiguration.java
index d4279b1..80ebe4d 100644
--- a/vxquery-xtest/src/main/java/org/apache/vxquery/xtest/TestConfiguration.java
+++ b/vxquery-xtest/src/main/java/org/apache/vxquery/xtest/TestConfiguration.java
@@ -17,6 +17,8 @@
package org.apache.vxquery.xtest;
import java.io.File;
+import java.util.HashMap;
+import java.util.Map;
public class TestConfiguration {
XTestOptions options;
@@ -30,4 +32,6 @@ public class TestConfiguration {
String xqueryFileExtension;
String xqueryxFileExtension;
-}
\ No newline at end of file
+
+ Map<String, File> sourceFileMap = new HashMap<String, File>();
+}
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/main/java/org/apache/vxquery/xtest/TestRunnerFactory.java
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/main/java/org/apache/vxquery/xtest/TestRunnerFactory.java b/vxquery-xtest/src/main/java/org/apache/vxquery/xtest/TestRunnerFactory.java
index 7900921..b9f1d70 100644
--- a/vxquery-xtest/src/main/java/org/apache/vxquery/xtest/TestRunnerFactory.java
+++ b/vxquery-xtest/src/main/java/org/apache/vxquery/xtest/TestRunnerFactory.java
@@ -23,9 +23,12 @@ import java.util.ArrayList;
import java.util.Collection;
import java.util.EnumSet;
import java.util.List;
+import java.util.Map;
import java.util.regex.Matcher;
import java.util.regex.Pattern;
+import javax.xml.namespace.QName;
+
import org.apache.vxquery.compiler.CompilerControlBlock;
import org.apache.vxquery.compiler.algebricks.VXQueryGlobalDataFactory;
import org.apache.vxquery.context.DynamicContext;
@@ -116,7 +119,7 @@ public class TestRunnerFactory {
Reader in = new InputStreamReader(new FileInputStream(testCase.getXQueryFile()), "UTF-8");
CompilerControlBlock ccb = new CompilerControlBlock(new StaticContextImpl(
RootStaticContextImpl.INSTANCE), new ResultSetId(testCase.getXQueryDisplayName()
- .hashCode()));
+ .hashCode()), testCase.getSourceFileMap());
compiler.compile(testCase.getXQueryDisplayName(), in, ccb, opts.optimizationLevel);
JobSpecification spec = compiler.getModule().getHyracksJobSpecification();
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-1/avg.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-1/avg.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-1/avg.txt
new file mode 100644
index 0000000..7ef6ffe
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-1/avg.txt
@@ -0,0 +1 @@
+12.5
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-1/count.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-1/count.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-1/count.txt
new file mode 100644
index 0000000..d8263ee
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-1/count.txt
@@ -0,0 +1 @@
+2
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-1/max.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-1/max.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-1/max.txt
new file mode 100644
index 0000000..dc7b54a
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-1/max.txt
@@ -0,0 +1 @@
+33
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-1/min.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-1/min.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-1/min.txt
new file mode 100644
index 0000000..ea1acb6
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-1/min.txt
@@ -0,0 +1 @@
+11.25
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-1/sum.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-1/sum.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-1/sum.txt
new file mode 100644
index 0000000..2b82dfe
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-1/sum.txt
@@ -0,0 +1 @@
+60
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-2/avg.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-2/avg.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-2/avg.txt
new file mode 100644
index 0000000..7ef6ffe
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-2/avg.txt
@@ -0,0 +1 @@
+12.5
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-2/count.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-2/count.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-2/count.txt
new file mode 100644
index 0000000..d8263ee
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-2/count.txt
@@ -0,0 +1 @@
+2
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-2/max.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-2/max.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-2/max.txt
new file mode 100644
index 0000000..dc7b54a
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-2/max.txt
@@ -0,0 +1 @@
+33
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-2/min.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-2/min.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-2/min.txt
new file mode 100644
index 0000000..ea1acb6
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-2/min.txt
@@ -0,0 +1 @@
+11.25
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-2/sum.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-2/sum.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-2/sum.txt
new file mode 100644
index 0000000..2b82dfe
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-2/sum.txt
@@ -0,0 +1 @@
+60
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-4/avg.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-4/avg.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-4/avg.txt
new file mode 100644
index 0000000..7ef6ffe
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-4/avg.txt
@@ -0,0 +1 @@
+12.5
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-4/count.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-4/count.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-4/count.txt
new file mode 100644
index 0000000..d8263ee
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-4/count.txt
@@ -0,0 +1 @@
+2
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-4/max.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-4/max.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-4/max.txt
new file mode 100644
index 0000000..dc7b54a
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-4/max.txt
@@ -0,0 +1 @@
+33
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-4/min.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-4/min.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-4/min.txt
new file mode 100644
index 0000000..ea1acb6
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-4/min.txt
@@ -0,0 +1 @@
+11.25
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-4/sum.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-4/sum.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-4/sum.txt
new file mode 100644
index 0000000..2b82dfe
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/Aggregate/Partition-4/sum.txt
@@ -0,0 +1 @@
+60
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-1/q00.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-1/q00.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-1/q00.txt
new file mode 100644
index 0000000..e6116d0
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-1/q00.txt
@@ -0,0 +1,2 @@
+<data><date>2003-03-03T00:00:00.000</date><dataType>TMIN</dataType><station>GHCND:AS000000003</station><value>13.75</value><attributes><attribute></attribute><attribute></attribute><attribute>a</attribute><attribute></attribute></attributes></data>
+<data><date>2003-03-03T00:00:00.000</date><dataType>TMAX</dataType><station>GHCND:AS000000003</station><value>33</value><attributes><attribute></attribute><attribute></attribute><attribute>a</attribute><attribute></attribute></attributes></data>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-1/q01.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-1/q01.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-1/q01.txt
new file mode 100644
index 0000000..ff4bc9b
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-1/q01.txt
@@ -0,0 +1 @@
+<data><date>2001-01-01T00:00:00.000</date><dataType>AWND</dataType><station>GHCND:US000000001</station><value>1000</value><attributes><attribute></attribute><attribute></attribute><attribute>a</attribute><attribute></attribute></attributes></data>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-1/q02.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-1/q02.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-1/q02.txt
new file mode 100644
index 0000000..d8263ee
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-1/q02.txt
@@ -0,0 +1 @@
+2
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-1/q03.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-1/q03.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-1/q03.txt
new file mode 100644
index 0000000..f30101c
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-1/q03.txt
@@ -0,0 +1 @@
+3.3
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-1/q04.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-1/q04.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-1/q04.txt
new file mode 100644
index 0000000..c5b9925
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-1/q04.txt
@@ -0,0 +1,3 @@
+<data><date>2002-02-02T00:00:00.000</date><dataType>TMIN</dataType><station>GHCND:US000000002</station><value>12.5</value><attributes><attribute></attribute><attribute></attribute><attribute>a</attribute><attribute></attribute></attributes></data>
+<data><date>2002-02-02T00:00:00.000</date><dataType>TMAX</dataType><station>GHCND:US000000002</station><value>32</value><attributes><attribute></attribute><attribute></attribute><attribute>a</attribute><attribute></attribute></attributes></data>
+<data><date>2002-02-02T00:00:00.000</date><dataType>PRCP</dataType><station>GHCND:US000000002</station><value>20</value><attributes><attribute></attribute><attribute></attribute><attribute>a</attribute><attribute></attribute></attributes></data>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-1/q05.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-1/q05.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-1/q05.txt
new file mode 100644
index 0000000..9f5aceb
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-1/q05.txt
@@ -0,0 +1 @@
+1.125
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-1/q06.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-1/q06.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-1/q06.txt
new file mode 100644
index 0000000..ca942fc
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-1/q06.txt
@@ -0,0 +1,3 @@
+<displayName>Station 2</displayName>
+<date>2002-02-02T00:00:00.000</date>
+<value>32</value>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-1/q07.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-1/q07.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-1/q07.txt
new file mode 100644
index 0000000..bfda7af
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-1/q07.txt
@@ -0,0 +1 @@
+1.95
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-2/q00.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-2/q00.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-2/q00.txt
new file mode 100644
index 0000000..e6116d0
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-2/q00.txt
@@ -0,0 +1,2 @@
+<data><date>2003-03-03T00:00:00.000</date><dataType>TMIN</dataType><station>GHCND:AS000000003</station><value>13.75</value><attributes><attribute></attribute><attribute></attribute><attribute>a</attribute><attribute></attribute></attributes></data>
+<data><date>2003-03-03T00:00:00.000</date><dataType>TMAX</dataType><station>GHCND:AS000000003</station><value>33</value><attributes><attribute></attribute><attribute></attribute><attribute>a</attribute><attribute></attribute></attributes></data>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-2/q01.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-2/q01.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-2/q01.txt
new file mode 100644
index 0000000..ff4bc9b
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-2/q01.txt
@@ -0,0 +1 @@
+<data><date>2001-01-01T00:00:00.000</date><dataType>AWND</dataType><station>GHCND:US000000001</station><value>1000</value><attributes><attribute></attribute><attribute></attribute><attribute>a</attribute><attribute></attribute></attributes></data>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-2/q02.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-2/q02.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-2/q02.txt
new file mode 100644
index 0000000..d8263ee
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-2/q02.txt
@@ -0,0 +1 @@
+2
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-2/q03.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-2/q03.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-2/q03.txt
new file mode 100644
index 0000000..f30101c
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-2/q03.txt
@@ -0,0 +1 @@
+3.3
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-2/q04.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-2/q04.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-2/q04.txt
new file mode 100644
index 0000000..c5b9925
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-2/q04.txt
@@ -0,0 +1,3 @@
+<data><date>2002-02-02T00:00:00.000</date><dataType>TMIN</dataType><station>GHCND:US000000002</station><value>12.5</value><attributes><attribute></attribute><attribute></attribute><attribute>a</attribute><attribute></attribute></attributes></data>
+<data><date>2002-02-02T00:00:00.000</date><dataType>TMAX</dataType><station>GHCND:US000000002</station><value>32</value><attributes><attribute></attribute><attribute></attribute><attribute>a</attribute><attribute></attribute></attributes></data>
+<data><date>2002-02-02T00:00:00.000</date><dataType>PRCP</dataType><station>GHCND:US000000002</station><value>20</value><attributes><attribute></attribute><attribute></attribute><attribute>a</attribute><attribute></attribute></attributes></data>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-2/q05.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-2/q05.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-2/q05.txt
new file mode 100644
index 0000000..9f5aceb
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-2/q05.txt
@@ -0,0 +1 @@
+1.125
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-2/q06.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-2/q06.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-2/q06.txt
new file mode 100644
index 0000000..ca942fc
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-2/q06.txt
@@ -0,0 +1,3 @@
+<displayName>Station 2</displayName>
+<date>2002-02-02T00:00:00.000</date>
+<value>32</value>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-2/q07.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-2/q07.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-2/q07.txt
new file mode 100644
index 0000000..bfda7af
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-2/q07.txt
@@ -0,0 +1 @@
+1.95
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-4/q00.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-4/q00.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-4/q00.txt
new file mode 100644
index 0000000..e6116d0
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-4/q00.txt
@@ -0,0 +1,2 @@
+<data><date>2003-03-03T00:00:00.000</date><dataType>TMIN</dataType><station>GHCND:AS000000003</station><value>13.75</value><attributes><attribute></attribute><attribute></attribute><attribute>a</attribute><attribute></attribute></attributes></data>
+<data><date>2003-03-03T00:00:00.000</date><dataType>TMAX</dataType><station>GHCND:AS000000003</station><value>33</value><attributes><attribute></attribute><attribute></attribute><attribute>a</attribute><attribute></attribute></attributes></data>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-4/q01.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-4/q01.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-4/q01.txt
new file mode 100644
index 0000000..ff4bc9b
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-4/q01.txt
@@ -0,0 +1 @@
+<data><date>2001-01-01T00:00:00.000</date><dataType>AWND</dataType><station>GHCND:US000000001</station><value>1000</value><attributes><attribute></attribute><attribute></attribute><attribute>a</attribute><attribute></attribute></attributes></data>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-4/q02.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-4/q02.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-4/q02.txt
new file mode 100644
index 0000000..d8263ee
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-4/q02.txt
@@ -0,0 +1 @@
+2
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-4/q03.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-4/q03.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-4/q03.txt
new file mode 100644
index 0000000..f30101c
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-4/q03.txt
@@ -0,0 +1 @@
+3.3
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-4/q04.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-4/q04.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-4/q04.txt
new file mode 100644
index 0000000..c5b9925
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-4/q04.txt
@@ -0,0 +1,3 @@
+<data><date>2002-02-02T00:00:00.000</date><dataType>TMIN</dataType><station>GHCND:US000000002</station><value>12.5</value><attributes><attribute></attribute><attribute></attribute><attribute>a</attribute><attribute></attribute></attributes></data>
+<data><date>2002-02-02T00:00:00.000</date><dataType>TMAX</dataType><station>GHCND:US000000002</station><value>32</value><attributes><attribute></attribute><attribute></attribute><attribute>a</attribute><attribute></attribute></attributes></data>
+<data><date>2002-02-02T00:00:00.000</date><dataType>PRCP</dataType><station>GHCND:US000000002</station><value>20</value><attributes><attribute></attribute><attribute></attribute><attribute>a</attribute><attribute></attribute></attributes></data>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-4/q05.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-4/q05.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-4/q05.txt
new file mode 100644
index 0000000..9f5aceb
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-4/q05.txt
@@ -0,0 +1 @@
+1.125
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-4/q06.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-4/q06.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-4/q06.txt
new file mode 100644
index 0000000..ca942fc
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-4/q06.txt
@@ -0,0 +1,3 @@
+<displayName>Station 2</displayName>
+<date>2002-02-02T00:00:00.000</date>
+<value>32</value>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-4/q07.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-4/q07.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-4/q07.txt
new file mode 100644
index 0000000..bfda7af
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/Ghcnd/Partition-4/q07.txt
@@ -0,0 +1 @@
+1.95
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndCount/Partition-1/q02_count.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndCount/Partition-1/q02_count.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndCount/Partition-1/q02_count.txt
new file mode 100644
index 0000000..56a6051
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndCount/Partition-1/q02_count.txt
@@ -0,0 +1 @@
+1
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndCount/Partition-1/q03_count.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndCount/Partition-1/q03_count.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndCount/Partition-1/q03_count.txt
new file mode 100644
index 0000000..e440e5c
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndCount/Partition-1/q03_count.txt
@@ -0,0 +1 @@
+3
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndCount/Partition-1/q05_count.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndCount/Partition-1/q05_count.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndCount/Partition-1/q05_count.txt
new file mode 100644
index 0000000..56a6051
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndCount/Partition-1/q05_count.txt
@@ -0,0 +1 @@
+1
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndCount/Partition-1/q07_count.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndCount/Partition-1/q07_count.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndCount/Partition-1/q07_count.txt
new file mode 100644
index 0000000..e440e5c
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndCount/Partition-1/q07_count.txt
@@ -0,0 +1 @@
+3
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndCount/Partition-2/q02_count.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndCount/Partition-2/q02_count.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndCount/Partition-2/q02_count.txt
new file mode 100644
index 0000000..56a6051
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndCount/Partition-2/q02_count.txt
@@ -0,0 +1 @@
+1
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndCount/Partition-2/q03_count.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndCount/Partition-2/q03_count.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndCount/Partition-2/q03_count.txt
new file mode 100644
index 0000000..e440e5c
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndCount/Partition-2/q03_count.txt
@@ -0,0 +1 @@
+3
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndCount/Partition-2/q05_count.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndCount/Partition-2/q05_count.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndCount/Partition-2/q05_count.txt
new file mode 100644
index 0000000..56a6051
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndCount/Partition-2/q05_count.txt
@@ -0,0 +1 @@
+1
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndCount/Partition-2/q07_count.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndCount/Partition-2/q07_count.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndCount/Partition-2/q07_count.txt
new file mode 100644
index 0000000..e440e5c
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndCount/Partition-2/q07_count.txt
@@ -0,0 +1 @@
+3
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndCount/Partition-4/q02_count.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndCount/Partition-4/q02_count.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndCount/Partition-4/q02_count.txt
new file mode 100644
index 0000000..56a6051
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndCount/Partition-4/q02_count.txt
@@ -0,0 +1 @@
+1
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndCount/Partition-4/q03_count.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndCount/Partition-4/q03_count.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndCount/Partition-4/q03_count.txt
new file mode 100644
index 0000000..e440e5c
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndCount/Partition-4/q03_count.txt
@@ -0,0 +1 @@
+3
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndCount/Partition-4/q05_count.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndCount/Partition-4/q05_count.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndCount/Partition-4/q05_count.txt
new file mode 100644
index 0000000..56a6051
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndCount/Partition-4/q05_count.txt
@@ -0,0 +1 @@
+1
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndCount/Partition-4/q07_count.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndCount/Partition-4/q07_count.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndCount/Partition-4/q07_count.txt
new file mode 100644
index 0000000..e440e5c
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndCount/Partition-4/q07_count.txt
@@ -0,0 +1 @@
+3
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndRecords/Partition-1/q02_records.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndRecords/Partition-1/q02_records.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndRecords/Partition-1/q02_records.txt
new file mode 100644
index 0000000..a533a86
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndRecords/Partition-1/q02_records.txt
@@ -0,0 +1 @@
+<value>20</value>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndRecords/Partition-1/q03_records.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndRecords/Partition-1/q03_records.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndRecords/Partition-1/q03_records.txt
new file mode 100644
index 0000000..8d77b4d
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndRecords/Partition-1/q03_records.txt
@@ -0,0 +1,3 @@
+<value>31</value>
+<value>32</value>
+<value>33</value>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndRecords/Partition-1/q05_records.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndRecords/Partition-1/q05_records.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndRecords/Partition-1/q05_records.txt
new file mode 100644
index 0000000..802ab3c
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndRecords/Partition-1/q05_records.txt
@@ -0,0 +1 @@
+<value>11.25</value>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndRecords/Partition-1/q07_records.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndRecords/Partition-1/q07_records.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndRecords/Partition-1/q07_records.txt
new file mode 100644
index 0000000..fdd1637
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndRecords/Partition-1/q07_records.txt
@@ -0,0 +1,3 @@
+19.75
+19.5
+19.25
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndRecords/Partition-2/q02_records.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndRecords/Partition-2/q02_records.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndRecords/Partition-2/q02_records.txt
new file mode 100644
index 0000000..a533a86
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndRecords/Partition-2/q02_records.txt
@@ -0,0 +1 @@
+<value>20</value>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndRecords/Partition-2/q03_records.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndRecords/Partition-2/q03_records.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndRecords/Partition-2/q03_records.txt
new file mode 100644
index 0000000..8d77b4d
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndRecords/Partition-2/q03_records.txt
@@ -0,0 +1,3 @@
+<value>31</value>
+<value>32</value>
+<value>33</value>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndRecords/Partition-2/q05_records.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndRecords/Partition-2/q05_records.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndRecords/Partition-2/q05_records.txt
new file mode 100644
index 0000000..802ab3c
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndRecords/Partition-2/q05_records.txt
@@ -0,0 +1 @@
+<value>11.25</value>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndRecords/Partition-2/q07_records.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndRecords/Partition-2/q07_records.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndRecords/Partition-2/q07_records.txt
new file mode 100644
index 0000000..fdd1637
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndRecords/Partition-2/q07_records.txt
@@ -0,0 +1,3 @@
+19.75
+19.5
+19.25
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndRecords/Partition-4/q02_records.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndRecords/Partition-4/q02_records.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndRecords/Partition-4/q02_records.txt
new file mode 100644
index 0000000..a533a86
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndRecords/Partition-4/q02_records.txt
@@ -0,0 +1 @@
+<value>20</value>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndRecords/Partition-4/q03_records.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndRecords/Partition-4/q03_records.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndRecords/Partition-4/q03_records.txt
new file mode 100644
index 0000000..8d77b4d
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndRecords/Partition-4/q03_records.txt
@@ -0,0 +1,3 @@
+<value>31</value>
+<value>32</value>
+<value>33</value>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndRecords/Partition-4/q05_records.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndRecords/Partition-4/q05_records.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndRecords/Partition-4/q05_records.txt
new file mode 100644
index 0000000..802ab3c
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndRecords/Partition-4/q05_records.txt
@@ -0,0 +1 @@
+<value>11.25</value>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndRecords/Partition-4/q07_records.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndRecords/Partition-4/q07_records.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndRecords/Partition-4/q07_records.txt
new file mode 100644
index 0000000..fdd1637
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/GhcndRecords/Partition-4/q07_records.txt
@@ -0,0 +1,3 @@
+19.75
+19.5
+19.25
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/Queries/XQuery/Aggregate/Partition-1/avg.xq
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/Queries/XQuery/Aggregate/Partition-1/avg.xq b/vxquery-xtest/src/test/resources/Queries/XQuery/Aggregate/Partition-1/avg.xq
new file mode 100644
index 0000000..c781bf1
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/Queries/XQuery/Aggregate/Partition-1/avg.xq
@@ -0,0 +1,8 @@
+(: XQuery Aggregate Query :)
+(: Find the average minimum temperature. :)
+fn:avg(
+ let $collection := "ghcnd"
+ for $r in collection($collection)/dataCollection/data
+ where $r/dataType eq "TMIN"
+ return $r/value
+)
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/Queries/XQuery/Aggregate/Partition-1/count.xq
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/Queries/XQuery/Aggregate/Partition-1/count.xq b/vxquery-xtest/src/test/resources/Queries/XQuery/Aggregate/Partition-1/count.xq
new file mode 100644
index 0000000..673ce08
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/Queries/XQuery/Aggregate/Partition-1/count.xq
@@ -0,0 +1,8 @@
+(: XQuery Aggregate Query :)
+(: Find the number of wind sensor readings. :)
+fn:count(
+ let $collection := "ghcnd"
+ for $r in collection($collection)/dataCollection/data
+ where $r/dataType eq "AWND"
+ return $r/value
+)
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/Queries/XQuery/Aggregate/Partition-1/max.xq
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/Queries/XQuery/Aggregate/Partition-1/max.xq b/vxquery-xtest/src/test/resources/Queries/XQuery/Aggregate/Partition-1/max.xq
new file mode 100644
index 0000000..37c44ad
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/Queries/XQuery/Aggregate/Partition-1/max.xq
@@ -0,0 +1,8 @@
+(: XQuery Aggregate Query :)
+(: Find the highest max temperature. :)
+fn:max(
+ let $collection := "ghcnd"
+ for $r in collection($collection)/dataCollection/data
+ where $r/dataType eq "TMAX"
+ return $r/value
+)
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/Queries/XQuery/Aggregate/Partition-1/min.xq
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/Queries/XQuery/Aggregate/Partition-1/min.xq b/vxquery-xtest/src/test/resources/Queries/XQuery/Aggregate/Partition-1/min.xq
new file mode 100644
index 0000000..a0ae3ff
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/Queries/XQuery/Aggregate/Partition-1/min.xq
@@ -0,0 +1,8 @@
+(: XQuery Aggregate Query :)
+(: Find the lowest min temperature. :)
+fn:min(
+ let $collection := "ghcnd"
+ for $r in collection($collection)/dataCollection/data
+ where $r/dataType eq "TMIN"
+ return $r/value
+)
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/Queries/XQuery/Aggregate/Partition-1/sum.xq
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/Queries/XQuery/Aggregate/Partition-1/sum.xq b/vxquery-xtest/src/test/resources/Queries/XQuery/Aggregate/Partition-1/sum.xq
new file mode 100644
index 0000000..8837123
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/Queries/XQuery/Aggregate/Partition-1/sum.xq
@@ -0,0 +1,8 @@
+(: XQuery Aggregate Query :)
+(: Find the total precipitation. :)
+fn:sum(
+ let $collection := "ghcnd"
+ for $r in collection($collection)/dataCollection/data
+ where $r/dataType eq "PRCP"
+ return $r/value
+)
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/fc9c5bf1/vxquery-xtest/src/test/resources/Queries/XQuery/Aggregate/Partition-2/avg.xq
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/Queries/XQuery/Aggregate/Partition-2/avg.xq b/vxquery-xtest/src/test/resources/Queries/XQuery/Aggregate/Partition-2/avg.xq
new file mode 100644
index 0000000..09fe30c
--- /dev/null
+++ b/vxquery-xtest/src/test/resources/Queries/XQuery/Aggregate/Partition-2/avg.xq
@@ -0,0 +1,8 @@
+(: XQuery Aggregate Query :)
+(: Find the average minimum temperature. :)
+fn:avg(
+ let $collection := "ghcnd_half_1|ghcnd_half_2"
+ for $r in collection($collection)/dataCollection/data
+ where $r/dataType eq "TMIN"
+ return $r/value
+)