http://git-wip-us.apache.org/repos/asf/asterixdb/blob/f372c96d/asterixdb/asterix-app/src/test/resources/optimizerts/queries/nested-open-index/rtree-index-join/leftouterjoin-probe-pidx-with-join-rtree-sidx_02.aql ---------------------------------------------------------------------- diff --git a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/nested-open-index/rtree-index-join/leftouterjoin-probe-pidx-with-join-rtree-sidx_02.aql b/asterixdb/asterix-app/src/test/resources/optimizerts/queries/nested-open-index/rtree-index-join/leftouterjoin-probe-pidx-with-join-rtree-sidx_02.aql deleted file mode 100644 index 8499c9a..0000000 --- a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/nested-open-index/rtree-index-join/leftouterjoin-probe-pidx-with-join-rtree-sidx_02.aql +++ /dev/null @@ -1,74 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - */ -/* - * Description : Test that left-outer-join may use two available indexes, one for primary index in prob subtree and another for secondary rtree index in index subtree. - * Issue : 730, 741 - * Expected Res : Success - * Date : 8th May 2014 - */ - -drop dataverse test if exists; -create dataverse test; -use dataverse test; - -create type TwitterUserType as closed { - screen-name: string, - lang: string, - friends-count: int32, - statuses-count: int32, - name: string, - followers-count: int32 -} - -create type TweetMessageNestedType as open { - tweetid: int64, - user: TwitterUserType, - send-time: datetime, - referred-topics: {{ string }}, - message-text: string, - countA: int32, - countB: int32 -} - -create type TweetMessageType as open { - nested: TweetMessageNestedType -} - -create dataset TweetMessages(TweetMessageType) -primary key nested.tweetid; - -create index twmSndLocIx on TweetMessages(nested.sender-location: point?) type rtree enforced; -create index msgCountAIx on TweetMessages(nested.countA) type btree; -create index msgCountBIx on TweetMessages(nested.countB) type btree; -create index msgTextIx on TweetMessages(nested.message-text) type keyword; - -write output to asterix_nc1:"rttest/rtree-index-join_leftouterjoin-probe-pidx-with-join-rtree-sidx_02.adm"; - -for $t1 in dataset('TweetMessages') -let $n := create-circle($t1.nested.sender-location, 0.5) -where $t1.nested.tweetid < int64("10") -order by $t1.nested.tweetid -return { -"tweetid1": $t1.nested.tweetid, -"loc1":$t1.nested.sender-location, -"nearby-message": for $t2 in dataset('TweetMessages') - where spatial-intersect($t2.nested.sender-location, $n) and $t1.nested.tweetid != $t2.nested.tweetid - order by $t2.nested.tweetid - return {"tweetid2":$t2.nested.tweetid, "loc2":$t2.nested.sender-location} -};
http://git-wip-us.apache.org/repos/asf/asterixdb/blob/f372c96d/asterixdb/asterix-app/src/test/resources/optimizerts/queries/nested-open-index/rtree-index-join/spatial-intersect-point_02.aql ---------------------------------------------------------------------- diff --git a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/nested-open-index/rtree-index-join/spatial-intersect-point_02.aql b/asterixdb/asterix-app/src/test/resources/optimizerts/queries/nested-open-index/rtree-index-join/spatial-intersect-point_02.aql deleted file mode 100644 index bed6626..0000000 --- a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/nested-open-index/rtree-index-join/spatial-intersect-point_02.aql +++ /dev/null @@ -1,55 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - */ -/* - * Description : Joins two datasets on the intersection of their point attributes. - * The dataset 'MyData2' has an enforced open RTree index?, and we expect the - * join to be transformed into an indexed nested-loop join. - * Success : Yes - */ - -drop dataverse test if exists; -create dataverse test; -use dataverse test; - -create type MyRecord as closed { - id: int32, - point: point, - kwds: string, - line1: line, - line2: line, - poly1: polygon, - poly2: polygon, - rec: rectangle -} - -create type MyRecordNested as closed { - nested: MyRecord -} - -create dataset MyData1(MyRecordNested) primary key nested.id; -create dataset MyData2(MyRecord) primary key id; - -create index rtree_index on MyData2(point) type rtree; - -write output to asterix_nc1:"rttest/rtree-index-join_spatial-intersect-point_02.adm"; - -for $a in dataset('MyData1') -for $b in dataset('MyData2') -where spatial-intersect($a.nested.point, $b.point) -return {"a": $a, "b": $b} http://git-wip-us.apache.org/repos/asf/asterixdb/blob/f372c96d/asterixdb/asterix-app/src/test/resources/optimizerts/queries/nested-open-index/rtree-index-join/spatial-intersect-point_03.aql ---------------------------------------------------------------------- diff --git a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/nested-open-index/rtree-index-join/spatial-intersect-point_03.aql b/asterixdb/asterix-app/src/test/resources/optimizerts/queries/nested-open-index/rtree-index-join/spatial-intersect-point_03.aql deleted file mode 100644 index e991ee8..0000000 --- a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/nested-open-index/rtree-index-join/spatial-intersect-point_03.aql +++ /dev/null @@ -1,53 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - */ -/* - * Description : Self-joins a dataset on the intersection of its point attribute. - * The dataset has an enforced open RTree index?, and we expect the - * join to be transformed into an indexed nested-loop join. - * Success : Yes - */ - -drop dataverse test if exists; -create dataverse test; -use dataverse test; - -create type MyRecord as closed { - id: int32, - point: point, - kwds: string, - line1: line, - line2: line, - poly1: polygon, - poly2: polygon, - rec: rectangle -} - -create type MyRecordNested as closed { - nested: MyRecord -} -create dataset MyData(MyRecordNested) primary key nested.id; - -create index rtree_index on MyData(nested.point) type rtree; - -write output to asterix_nc1:"rttest/rtree-index-join_spatial-intersect-point_03.adm"; - -for $a in dataset('MyData') -for $b in dataset('MyData') -where spatial-intersect($a.nested.point, $b.nested.point) -return {"a": $a, "b": $b} http://git-wip-us.apache.org/repos/asf/asterixdb/blob/f372c96d/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index-join/secondary-equi-join-multiindex.aql ---------------------------------------------------------------------- diff --git a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index-join/secondary-equi-join-multiindex.aql b/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index-join/secondary-equi-join-multiindex.aql deleted file mode 100644 index af51a69..0000000 --- a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index-join/secondary-equi-join-multiindex.aql +++ /dev/null @@ -1,77 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - */ -/* - * Description : Equi joins two datasets, FacebookUsers and FacebookMessages, based on their user's id. - * We first expect FacebookUsers' primary index to be used - * to satisfy the range condition on it's primary key. - * FacebookMessages has a secondary btree open index on author-id-copy, and given the 'indexnl' hint - * we expect the join to be transformed into an indexed nested-loop join. - * Success : Yes - */ - -drop dataverse test if exists; -create dataverse test; -use dataverse test; - -create type EmploymentType as closed { - organization-name: string, - start-date: date, - end-date: date? -} - -create type FacebookUserType as closed { - id: int32, - id-copy: int32, - alias: string, - name: string, - user-since: datetime, - user-since-copy: datetime, - friend-ids: {{ int32 }}, - employment: [EmploymentType] -} - -create type FacebookMessageType as open { - message-id: int32, - message-id-copy: int32, - author-id: int32, - in-response-to: int32?, - sender-location: point?, - message: string -} - -create dataset FacebookUsers(FacebookUserType) -primary key id; - -create dataset FacebookMessages(FacebookMessageType) -primary key message-id; - -create index fbmIdxAutId if not exists on FacebookMessages(author-id-copy:int32?) enforced; - -write output to asterix_nc1:"rttest/btree-index-join_title-secondary-equi-join-multiindex.adm"; - -for $user in dataset('FacebookUsers') -for $message in dataset('FacebookMessages') -where $user.id /*+ indexnl */ = $message.author-id-copy -and $user.id >= 11000 and $user.id <= 12000 -return { - "fbu-ID": $user.id, - "fbm-auth-ID": $message.author-id, - "uname": $user.name, - "message": $message.message -} http://git-wip-us.apache.org/repos/asf/asterixdb/blob/f372c96d/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index-join/secondary-equi-join_02.aql ---------------------------------------------------------------------- diff --git a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index-join/secondary-equi-join_02.aql b/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index-join/secondary-equi-join_02.aql deleted file mode 100644 index 247b5e0..0000000 --- a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index-join/secondary-equi-join_02.aql +++ /dev/null @@ -1,56 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - */ -/* - * Description : Equi joins two datasets, DBLP and CSX, based on their title. - * CSX has a secondary btree open index on title, and given the 'indexnl' hint - * we expect the join to be transformed into an indexed nested-loop join. - * Success : Yes - */ - -drop dataverse test if exists; -create dataverse test; -use dataverse test; - -create type DBLPType as closed { - id: int32, - dblpid: string, - title: string, - authors: string, - misc: string -} - -create type CSXType as open { - id: int32, - csxid: string, - authors: string, - misc: string -} - -create dataset DBLP(DBLPType) primary key id; - -create dataset CSX(CSXType) primary key id; - -create index title_index on CSX(title:string?) enforced; - -write output to asterix_nc1:"rttest/btree-index-join_title-secondary-equi-join_02.adm"; - -for $a in dataset('DBLP') -for $b in dataset('CSX') -where $a.title /*+ indexnl */ = $b.title -return {"arec": $a, "brec": $b} http://git-wip-us.apache.org/repos/asf/asterixdb/blob/f372c96d/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index-join/secondary-equi-join_03.aql ---------------------------------------------------------------------- diff --git a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index-join/secondary-equi-join_03.aql b/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index-join/secondary-equi-join_03.aql deleted file mode 100644 index a414ba3..0000000 --- a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index-join/secondary-equi-join_03.aql +++ /dev/null @@ -1,46 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - */ -/* - * Description : Equi self-joins a dataset, DBLP, based on its title. - * DBLP has a secondary btree open index on title, and given the 'indexnl' hint - * we expect the join to be transformed into an indexed nested-loop join. - * Success : Yes - */ - -drop dataverse test if exists; -create dataverse test; -use dataverse test; - -create type DBLPType as open { - id: int32, - dblpid: string, - authors: string, - misc: string -} - -create dataset DBLP(DBLPType) primary key id; - -create index title_index on DBLP(title:string?) enforced; - -write output to asterix_nc1:"rttest/btree-index-join_title-secondary-equi-join_03.adm"; - -for $a in dataset('DBLP') -for $b in dataset('DBLP') -where $a.title /*+ indexnl */ = $b.title -return {"arec": $a, "brec": $b} http://git-wip-us.apache.org/repos/asf/asterixdb/blob/f372c96d/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index-join/secondary-equi-join_04.aql ---------------------------------------------------------------------- diff --git a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index-join/secondary-equi-join_04.aql b/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index-join/secondary-equi-join_04.aql deleted file mode 100644 index 8b78831..0000000 --- a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index-join/secondary-equi-join_04.aql +++ /dev/null @@ -1,57 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - */ -/* - * Description : Equi joins two datasets, DBLP and CSX, based on their title. - * Both DBLP and CSX have secondary btree open index on title, and given the 'indexnl' hint - * we expect the join to be transformed into an indexed nested-loop join. - * Success : Yes - */ - -drop dataverse test if exists; -create dataverse test; -use dataverse test; - -create type DBLPType as open { - id: int32, - dblpid: string, - authors: string, - misc: string -} - -create type CSXType as open { - id: int32, - csxid: string, - authors: string, - misc: string -} - -create dataset DBLP(DBLPType) primary key id; - -create dataset CSX(CSXType) primary key id; - -create index title_index_DBLP on DBLP(title:string?) enforced; - -create index title_index on CSX(title:string?) enforced; - -write output to asterix_nc1:"rttest/btree-index-join_title-secondary-equi-join_02.adm"; - -for $a in dataset('DBLP') -for $b in dataset('CSX') -where $a.title /*+ indexnl */ = $b.title -return {"arec": $a, "brec": $b} http://git-wip-us.apache.org/repos/asf/asterixdb/blob/f372c96d/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index-join/secondary-equi-join_05.aql ---------------------------------------------------------------------- diff --git a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index-join/secondary-equi-join_05.aql b/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index-join/secondary-equi-join_05.aql deleted file mode 100644 index 85a4495..0000000 --- a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index-join/secondary-equi-join_05.aql +++ /dev/null @@ -1,56 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - */ -/* - * Description : Equi joins two datasets, DBLP and CSX, based on their title. - * DBLP has a secondary btree open index on title, and given the 'indexnl' hint - * we *do not* expect the join to be transformed into an indexed nested-loop join, - * because CSX does not declare an enforced open index on field title. - * Success : Yes - */ - -drop dataverse test if exists; -create dataverse test; -use dataverse test; - -create type DBLPType as open { - id: int32, - dblpid: string, - authors: string, - misc: string -} - -create type CSXType as open { - id: int32, - csxid: string, - authors: string, - misc: string -} - -create dataset DBLP(DBLPType) primary key id; - -create dataset CSX(CSXType) primary key id; - -create index title_index on DBLP(title:string?) enforced; - -write output to asterix_nc1:"rttest/btree-index-join_title-secondary-equi-join_02.adm"; - -for $a in dataset('DBLP') -for $b in dataset('CSX') -where $a.title /*+ indexnl */ = $b.title -return {"arec": $a, "brec": $b} http://git-wip-us.apache.org/repos/asf/asterixdb/blob/f372c96d/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-33.aql ---------------------------------------------------------------------- diff --git a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-33.aql b/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-33.aql deleted file mode 100644 index 4c5c2b8..0000000 --- a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-33.aql +++ /dev/null @@ -1,45 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - */ -/* - * Description : BTree Index verification test - * : This test is intended to verify that the secondary BTree index is NOT used - * : in the optimized query plan. - * Expected Result : Success - * Date : 26th Mar 2014 - */ - -// Please note this is a Negative test and the BTree index should NOT be used in the plan. - -drop dataverse test if exists; -create dataverse test; -use dataverse test; - -write output to asterix_nc1:"rttest/btree-index_btree-primary-31.adm"; - -create type TestType as open { - id : int32 -} - -create dataset testdst(TestType) primary key id; - -create index sec_Idx on testdst(fname:string?,lname:string?) enforced; - -for $emp in dataset('testdst') -where $emp.fname > "Roger" -return $emp http://git-wip-us.apache.org/repos/asf/asterixdb/blob/f372c96d/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-34.aql ---------------------------------------------------------------------- diff --git a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-34.aql b/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-34.aql deleted file mode 100644 index 4aee42a..0000000 --- a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-34.aql +++ /dev/null @@ -1,45 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - */ -/* - * Description : BTree Index verification test - * : This test is intended to verify that the secondary BTree index is NOT used - * : in the optimized query plan. - * Expected Result : Success - * Date : 26th Mar 2014 - */ - -// This is a Negative test - prefix search, BTree index should not be used in the plan. - -drop dataverse test if exists; -create dataverse test; -use dataverse test; - -write output to asterix_nc1:"rttest/btree-index_btree-secondary-32.adm"; - -create type TestType as open { - id : int32 -} - -create dataset testdst(TestType) primary key id; - -create index sec_Idx on testdst(fname:string?,lname:string?) enforced; - -for $emp in dataset('testdst') -where $emp.fname >= "Susan" -return $emp http://git-wip-us.apache.org/repos/asf/asterixdb/blob/f372c96d/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-35.aql ---------------------------------------------------------------------- diff --git a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-35.aql b/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-35.aql deleted file mode 100644 index 549db84..0000000 --- a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-35.aql +++ /dev/null @@ -1,45 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - */ -/* - * Description : BTree Index verification (usage) test - * : This test is intended to verify that the secondary BTree index is used - * : in the optimized query plan. - * Expected Result : Success - * Date : 26th Mar 2014 - */ - -// Negative test - prefix search, BTree index should not be used. - -drop dataverse test if exists; -create dataverse test; -use dataverse test; - -write output to asterix_nc1:"rttest/btree-index_btree-secondary-33.adm"; - -create type TestType as open { - id : int32 -} - -create dataset testdst(TestType) primary key id; - -create index sec_Idx on testdst(fname:string?,lname:string?) enforced; - -for $emp in dataset('testdst') -where $emp.fname < "Isa" -return $emp http://git-wip-us.apache.org/repos/asf/asterixdb/blob/f372c96d/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-36.aql ---------------------------------------------------------------------- diff --git a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-36.aql b/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-36.aql deleted file mode 100644 index 5d181fc..0000000 --- a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-36.aql +++ /dev/null @@ -1,45 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - */ -/* - * Description : BTree Index verification test - * : This test is intended to verify that the secondary BTree index is NOT used - * : in the optimized query plan. - * Expected Result : Success - * Date : 26th Mar 2014 - */ - -// Negative test - prefix search, BTree index should not be used in query plan - -drop dataverse test if exists; -create dataverse test; -use dataverse test; - -write output to asterix_nc1:"rttest/btree-index_btree-secondary-34.adm"; - -create type TestType as open { - id : int32 -} - -create dataset testdst(TestType) primary key id; - -create index sec_Idx on testdst(fname:string?,lname:string?) enforced; - -for $emp in dataset('testdst') -where $emp.fname <= "Vanpatten" -return $emp http://git-wip-us.apache.org/repos/asf/asterixdb/blob/f372c96d/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-40.aql ---------------------------------------------------------------------- diff --git a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-40.aql b/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-40.aql deleted file mode 100644 index 0f42145..0000000 --- a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-40.aql +++ /dev/null @@ -1,42 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - */ -/* - * Description : BTree Index verification test - * : This test is intended to verify that the secondary BTree index is used in the optimized query plan - * Expected Result : Success - * Date : 26th Mar 2014 - */ - -drop dataverse test if exists; -create dataverse test; -use dataverse test; - -write output to asterix_nc1:"rttest/btree-index_btree-secondary-38.adm"; - -create type TestType as open { - id : int32 -} - -create dataset testdst(TestType) primary key id; - -create index sec_Idx on testdst(fname:string?,lname:string?) enforced; - -for $emp in dataset('testdst') -where $emp.fname = "Young Seok" and $emp.lname = "Kim" -return $emp http://git-wip-us.apache.org/repos/asf/asterixdb/blob/f372c96d/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-42.aql ---------------------------------------------------------------------- diff --git a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-42.aql b/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-42.aql deleted file mode 100644 index 63daef0..0000000 --- a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-42.aql +++ /dev/null @@ -1,43 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - */ -/* - * Description : BTree Index verification test - * : This test is intended to verify that the secondary BTree index is used - * : in the optimized query plan. - * Expected Result : Success - * Date : 26th Mar 2014 - */ - -drop dataverse test if exists; -create dataverse test; -use dataverse test; - -write output to asterix_nc1:"rttest/btree-index_btree-secondary-40.adm"; - -create type TestType as open { - id : int32 -} - -create dataset testdst(TestType) primary key id; - -create index sec_Idx on testdst(fname:string?,lname:string?) enforced; - -for $emp in dataset('testdst') -where $emp.fname > "Alex" and $emp.lname < "Zach" -return $emp http://git-wip-us.apache.org/repos/asf/asterixdb/blob/f372c96d/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-43.aql ---------------------------------------------------------------------- diff --git a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-43.aql b/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-43.aql deleted file mode 100644 index b584eee..0000000 --- a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-43.aql +++ /dev/null @@ -1,43 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - */ -/* - * Description : BTree Index verification test - * : This test is intended to verify that the secondary BTree index is NOT used - * : in the optimized query plan. - * Expected Result : Success - * Date : 26th Mar 2014 - */ - -drop dataverse test if exists; -create dataverse test; -use dataverse test; - -write output to asterix_nc1:"rttest/btree-index_btree-secondary-41.adm"; - -create type TestType as open { - id : int32 -} - -create dataset testdst(TestType) primary key id; - -create index sec_Idx on testdst(fname:string?,lname:string?) enforced; - -for $emp in dataset('testdst') -where $emp.fname > "Allan" and $emp.lname < "Zubi" -return $emp http://git-wip-us.apache.org/repos/asf/asterixdb/blob/f372c96d/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-44.aql ---------------------------------------------------------------------- diff --git a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-44.aql b/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-44.aql deleted file mode 100644 index 05b92c0..0000000 --- a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-44.aql +++ /dev/null @@ -1,45 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - */ -/* - * Description : BTree Index verification test - * : This test is intended to verify that the secondary BTree index is NOT used - * : in the optimized query plan. - * Expected Result : Success - * Date : 26th Mar 2014 - */ - -// Negative test - prefix search - -drop dataverse test if exists; -create dataverse test; -use dataverse test; - -write output to asterix_nc1:"rttest/btree-index_btree-secondary-42.adm"; - -create type TestType as open { - id : int32 -} - -create dataset testdst(TestType) primary key id; - -create index sec_Idx on testdst(fname:string?,lname:string?) enforced; - -for $emp in dataset('testdst') -where $emp.fname > "Allan" and $emp.lname = "Xu" -return $emp http://git-wip-us.apache.org/repos/asf/asterixdb/blob/f372c96d/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-45.aql ---------------------------------------------------------------------- diff --git a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-45.aql b/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-45.aql deleted file mode 100644 index a732af4..0000000 --- a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-45.aql +++ /dev/null @@ -1,45 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - */ -/* - * Description : BTree Index verification test - * : This test is intended to verify that the secondary BTree index is NOT used - * : in the optimized query plan. - * Expected Result : Success - * Date : 26th Mar 2014 - */ - -// Negative test - prefix search - -drop dataverse test if exists; -create dataverse test; -use dataverse test; - -write output to asterix_nc1:"rttest/btree-index_btree-secondary-43.adm"; - -create type TestType as open { - id : int32 -} - -create dataset testdst(TestType) primary key id; - -create index sec_Idx on testdst(fname:string?,lname:string?) enforced; - -for $emp in dataset('testdst') -where $emp.fname = "Julio" and $emp.lname < "Xu" -return $emp http://git-wip-us.apache.org/repos/asf/asterixdb/blob/f372c96d/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-46.aql ---------------------------------------------------------------------- diff --git a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-46.aql b/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-46.aql deleted file mode 100644 index efdae0a..0000000 --- a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-46.aql +++ /dev/null @@ -1,43 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - */ -/* - * Description : BTree Index verification test - * : This test is intended to verify that the secondary BTree index is NOT used - * : in the optimized query plan. - * Expected Result : Success - * Date : 26th Mar 2014 - */ - -drop dataverse test if exists; -create dataverse test; -use dataverse test; - -write output to asterix_nc1:"rttest/btree-index_btree-secondary-44.adm"; - -create type TestType as open { - id : int32 -} - -create dataset testdst(TestType) primary key id; - -create index sec_Idx on testdst(fname:string?,lname:string?) enforced; - -for $emp in dataset('testdst') -where $emp.fname >= "Michael" and $emp.lname <= "Xu" -return $emp http://git-wip-us.apache.org/repos/asf/asterixdb/blob/f372c96d/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-47.aql ---------------------------------------------------------------------- diff --git a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-47.aql b/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-47.aql deleted file mode 100644 index 4cd35eb..0000000 --- a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-47.aql +++ /dev/null @@ -1,43 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - */ -/* - * Description : BTree Index verification test - * : This test is intended to verify that the secondary BTree index is used - * : in the optimized query plan. - * Expected Result : Success - * Date : 26th Mar 2014 - */ - -drop dataverse test if exists; -create dataverse test; -use dataverse test; - -write output to asterix_nc1:"rttest/btree-index_btree-secondary-45.adm"; - -create type TestType as open { - id : int32 -} - -create dataset testdst(TestType) primary key id; - -create index sec_Idx on testdst(fname:string?,lname:string?) enforced; - -for $emp in dataset('testdst') -where $emp.fname > "Craig" and $emp.lname > "Kevin" and $emp.fname < "Mary" and $emp.lname < "Tomes" -return $emp http://git-wip-us.apache.org/repos/asf/asterixdb/blob/f372c96d/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-48.aql ---------------------------------------------------------------------- diff --git a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-48.aql b/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-48.aql deleted file mode 100644 index 83ab8e6..0000000 --- a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-48.aql +++ /dev/null @@ -1,43 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - */ -/* - * Description : BTree Index verification test - * : This test is intended to verify that the secondary BTree index is used - * : in the optimized query plan. - * Expected Result : Success - * Date : 26th Mar 2014 - */ - -drop dataverse test if exists; -create dataverse test; -use dataverse test; - -write output to asterix_nc1:"rttest/btree-index_btree-secondary-46.adm"; - -create type TestType as open { - id : int32 -} - -create dataset testdst(TestType) primary key id; - -create index sec_Idx on testdst(fname:string?,lname:string?) enforced; - -for $emp in dataset('testdst') -where $emp.fname >= "Craig" and $emp.lname >= "Kevin" and $emp.fname <= "Mary" and $emp.lname <= "Tomes" -return $emp http://git-wip-us.apache.org/repos/asf/asterixdb/blob/f372c96d/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-49.aql ---------------------------------------------------------------------- diff --git a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-49.aql b/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-49.aql deleted file mode 100644 index b255913..0000000 --- a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-49.aql +++ /dev/null @@ -1,43 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - */ -/* - * Description : BTree Index verification test - * : This test is intended to verify that the secondary BTree index is NOT used - * : in the optimized query plan. - * Expected Result : Success - * Date : 26th Mar 2014 - */ - -drop dataverse test if exists; -create dataverse test; -use dataverse test; - -write output to asterix_nc1:"rttest/btree-index_btree-secondary-47.adm"; - -create type TestType as open { - id : int32 -} - -create dataset testdst(TestType) primary key id; - -create index sec_Idx on testdst(fname:string?,lname:string?) enforced; - -for $emp in dataset('testdst') -where $emp.fname <= "Craig" and $emp.lname > "Kevin" -return $emp http://git-wip-us.apache.org/repos/asf/asterixdb/blob/f372c96d/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-51.aql ---------------------------------------------------------------------- diff --git a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-51.aql b/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-51.aql deleted file mode 100644 index 99baf52..0000000 --- a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-51.aql +++ /dev/null @@ -1,43 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - */ -/* - * Description : BTree Index verification test - * : This test is intended to verify that the secondary BTree index is used - * : in the optimized query plan. - * Expected Result : Success - * Date : 26th Mar 2014 - */ - -drop dataverse test if exists; -create dataverse test; -use dataverse test; - -write output to asterix_nc1:"rttest/btree-index_btree-secondary-49.adm"; - -create type TestType as open { - id : int32 -} - -create dataset testdst(TestType) primary key id; - -create index sec_Idx on testdst(fname:string?,lname:string?) enforced; - -for $emp in dataset('testdst') -where $emp.fname > "Craig" and $emp.lname > "Kevin" and $emp.fname <= "Mary" and $emp.lname <= "Tomes" -return $emp http://git-wip-us.apache.org/repos/asf/asterixdb/blob/f372c96d/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-52.aql ---------------------------------------------------------------------- diff --git a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-52.aql b/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-52.aql deleted file mode 100644 index 9d9f6f8..0000000 --- a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-52.aql +++ /dev/null @@ -1,43 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - */ -/* - * Description : BTree Index verification test - * : This test is intended to verify that the secondary BTree index is used - * : in the optimized query plan. - * Expected Result : Success - * Date : 26th Mar 2014 - */ - -drop dataverse test if exists; -create dataverse test; -use dataverse test; - -write output to asterix_nc1:"rttest/btree-index_btree-secondary-50.adm"; - -create type TestType as open { - id : int32 -} - -create dataset testdst(TestType) primary key id; - -create index sec_Idx on testdst(fname:string?,lname:string?) enforced; - -for $emp in dataset('testdst') -where $emp.fname >= "Craig" and $emp.lname >= "Kevin" and $emp.fname < "Mary" and $emp.lname < "Tomes" -return $emp http://git-wip-us.apache.org/repos/asf/asterixdb/blob/f372c96d/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-53.aql ---------------------------------------------------------------------- diff --git a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-53.aql b/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-53.aql deleted file mode 100644 index 9c70884..0000000 --- a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-53.aql +++ /dev/null @@ -1,43 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - */ -/* - * Description : BTree Index verification test - * : This test is intended to verify that the secondary BTree index is used - * : in the optimized query plan. - * Expected Result : Success - * Date : 26th Mar 2014 - */ - -drop dataverse test if exists; -create dataverse test; -use dataverse test; - -write output to asterix_nc1:"rttest/btree-index_btree-secondary-51.adm"; - -create type TestType as open { - id : int32 -} - -create dataset testdst(TestType) primary key id; - -create index sec_Idx on testdst(fname:string?,lname:string?) enforced; - -for $emp in dataset('testdst') -where $emp.fname >= "Craig" and $emp.lname <= "Kevin" and $emp.fname <= "Mary" and $emp.lname >= "Tomes" -return $emp http://git-wip-us.apache.org/repos/asf/asterixdb/blob/f372c96d/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-54.aql ---------------------------------------------------------------------- diff --git a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-54.aql b/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-54.aql deleted file mode 100644 index c8c9ae2..0000000 --- a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-54.aql +++ /dev/null @@ -1,42 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - */ -/* - * Description : This test is intended to verify that the secondary BTree index is used - * : in the optimized query plan. - * Expected Result : Success - * Date : 26th Mar 2014 - */ - -drop dataverse test if exists; -create dataverse test; -use dataverse test; - -write output to asterix_nc1:"rttest/btree-index_btree-secondary-52.adm"; - -create type TestType as open { - id : int32 -} - -create dataset testdst(TestType) primary key id; - -create index sec_Idx on testdst(fname:string?) enforced; - -for $emp in dataset('testdst') -where $emp.fname > "Max" -return $emp http://git-wip-us.apache.org/repos/asf/asterixdb/blob/f372c96d/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-55.aql ---------------------------------------------------------------------- diff --git a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-55.aql b/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-55.aql deleted file mode 100644 index 1497453..0000000 --- a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-55.aql +++ /dev/null @@ -1,42 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - */ -/* - * Description : This test is intended to verify that the secondary BTree index is used - * : in the optimized query plan. - * Expected Result : Success - * Date : 26th Mar 2014 - */ - -drop dataverse test if exists; -create dataverse test; -use dataverse test; - -write output to asterix_nc1:"rttest/btree-index_btree-secondary-53.adm"; - -create type TestType as open { - id : int32 -} - -create dataset testdst(TestType) primary key id; - -create index sec_Idx on testdst(fname:string?) enforced; - -for $emp in dataset('testdst') -where $emp.fname >= "Sofia" -return $emp http://git-wip-us.apache.org/repos/asf/asterixdb/blob/f372c96d/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-56.aql ---------------------------------------------------------------------- diff --git a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-56.aql b/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-56.aql deleted file mode 100644 index bfb9b8b..0000000 --- a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-56.aql +++ /dev/null @@ -1,42 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - */ -/* - * Description : This test is intended to verify that the secondary BTree index is used - * : in the optimized query plan. - * Expected Result : Success - * Date : 26th Mar 2014 - */ - -drop dataverse test if exists; -create dataverse test; -use dataverse test; - -write output to asterix_nc1:"rttest/btree-index_btree-secondary-54.adm"; - -create type TestType as open { - id : int32 -} - -create dataset testdst(TestType) primary key id; - -create index sec_Idx on testdst(fname:string?) enforced; - -for $emp in dataset('testdst') -where $emp.fname < "Chen" -return $emp http://git-wip-us.apache.org/repos/asf/asterixdb/blob/f372c96d/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-57.aql ---------------------------------------------------------------------- diff --git a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-57.aql b/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-57.aql deleted file mode 100644 index bca543b..0000000 --- a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-57.aql +++ /dev/null @@ -1,42 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - */ -/* - * Description : This test is intended to verify that the secondary BTree index is used - * : in the optimized query plan. - * Expected Result : Success - * Date : 26th Mar 2014 - */ - -drop dataverse test if exists; -create dataverse test; -use dataverse test; - -write output to asterix_nc1:"rttest/btree-index_btree-secondary-55.adm"; - -create type TestType as open { - id : int32 -} - -create dataset testdst(TestType) primary key id; - -create index sec_Idx on testdst(fname:string?) enforced; - -for $emp in dataset('testdst') -where $emp.fname <= "Julio" -return $emp http://git-wip-us.apache.org/repos/asf/asterixdb/blob/f372c96d/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-58.aql ---------------------------------------------------------------------- diff --git a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-58.aql b/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-58.aql deleted file mode 100644 index 0a0b69f..0000000 --- a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-58.aql +++ /dev/null @@ -1,42 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - */ -/* - * Description : This test is intended to verify that the primary BTree index is used - * : in the optimized query plan. - * Expected Result : Success - * Date : 26th Mar 2014 - */ - -drop dataverse test if exists; -create dataverse test; -use dataverse test; - -write output to asterix_nc1:"rttest/btree-index_btree-primary-56.adm"; - -create type TestType as open { - id : int32 -} - -create dataset testdst(TestType) primary key id; - -create index sec_Idx on testdst(fname:string?) enforced; - -for $emp in dataset('testdst') -where $emp.fname > "Neil" and $emp.fname < "Roger" -return $emp http://git-wip-us.apache.org/repos/asf/asterixdb/blob/f372c96d/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-59.aql ---------------------------------------------------------------------- diff --git a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-59.aql b/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-59.aql deleted file mode 100644 index c7e41e5..0000000 --- a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-59.aql +++ /dev/null @@ -1,42 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - */ -/* - * Description : This test is intended to verify that the secondary BTree index is used - * : in the optimized query plan. - * Expected Result : Success - * Date : 26th Mar 2014 - */ - -drop dataverse test if exists; -create dataverse test; -use dataverse test; - -write output to asterix_nc1:"rttest/btree-index_btree-secondary-57.adm"; - -create type TestType as open { - id : int32 -} - -create dataset testdst(TestType) primary key id; - -create index sec_Idx on testdst(fname:string?) enforced; - -for $emp in dataset('testdst') -where $emp.fname >= "Max" and $emp.fname <= "Roger" -return $emp http://git-wip-us.apache.org/repos/asf/asterixdb/blob/f372c96d/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-60.aql ---------------------------------------------------------------------- diff --git a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-60.aql b/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-60.aql deleted file mode 100644 index 38c265c..0000000 --- a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-60.aql +++ /dev/null @@ -1,42 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - */ -/* - * Description : This test is intended to verify that the secondary BTree index is used - * : in the optimized query plan. - * Expected Result : Success - * Date : 26th Mar 2014 - */ - -drop dataverse test if exists; -create dataverse test; -use dataverse test; - -write output to asterix_nc1:"rttest/btree-index_btree-secondary-58.adm"; - -create type TestType as open { - id : int32 -} - -create dataset testdst(TestType) primary key id; - -create index sec_Idx on testdst(fname:string?) enforced; - -for $emp in dataset('testdst') -where $emp.fname = "Max" -return $emp http://git-wip-us.apache.org/repos/asf/asterixdb/blob/f372c96d/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-61.aql ---------------------------------------------------------------------- diff --git a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-61.aql b/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-61.aql deleted file mode 100644 index 840c227..0000000 --- a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-61.aql +++ /dev/null @@ -1,43 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - */ -/* - * Description : BTree Index verification test - * : This test is intended to verify that the secondary BTree index is used - * : in the optimized query plan. - * Expected Result : Success - * Date : 26th Mar 2014 - */ - -drop dataverse test if exists; -create dataverse test; -use dataverse test; - -write output to asterix_nc1:"rttest/btree-index_btree-secondary-49.adm"; - -create type TestType as open { - id : int32 -} - -create dataset testdst(TestType) primary key id; - -create index sec_Idx on testdst(fname:string?,lname:string?) enforced; - -for $emp in dataset('testdst') -where $emp.fname > "Craig" and $emp.lname > "Kevin" and $emp.fname <= "Mary" and $emp.lname < "Tomes" -return $emp http://git-wip-us.apache.org/repos/asf/asterixdb/blob/f372c96d/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-62.aql ---------------------------------------------------------------------- diff --git a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-62.aql b/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-62.aql deleted file mode 100644 index cf06de7..0000000 --- a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-62.aql +++ /dev/null @@ -1,45 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - */ -/* - * Description : BTree Index verification test - * : This test is intended to verify that the secondary BTree index is used - * : in the optimized query plan. - * Expected Result : Success - * Date : 11th Nov 2014 - */ - -// Positive test - prefix search - -drop dataverse test if exists; -create dataverse test; -use dataverse test; - -write output to asterix_nc1:"rttest/btree-index_btree-secondary-62.adm"; - -create type TestType as open { - id : int32 -} - -create dataset testdst(TestType) primary key id; - -create index sec_Idx on testdst(fname:string?,lname:string?) enforced; - -for $emp in dataset('testdst') -where $emp.fname = "Julio" and $emp.lname > "Xu" -return $emp http://git-wip-us.apache.org/repos/asf/asterixdb/blob/f372c96d/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-63.aql ---------------------------------------------------------------------- diff --git a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-63.aql b/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-63.aql deleted file mode 100644 index c34770b..0000000 --- a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/btree-index/btree-secondary-63.aql +++ /dev/null @@ -1,45 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - */ -/* - * Description : BTree Index verification test - * : This test is intended to verify that the secondary BTree index is used - * : in the optimized query plan. - * Expected Result : Success - * Date : 11th Nov 2014 - */ - -// Positive test - prefix search - -drop dataverse test if exists; -create dataverse test; -use dataverse test; - -write output to asterix_nc1:"rttest/btree-index_btree-secondary-63.adm"; - -create type TestType as open { - id : int32 -} - -create dataset testdst(TestType) primary key id; - -create index sec_Idx on testdst(fname:string?,lname:string?) enforced; - -for $emp in dataset('testdst') -where $emp.fname < "Julio" and $emp.lname = "Xu" -return $emp http://git-wip-us.apache.org/repos/asf/asterixdb/blob/f372c96d/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/inverted-index-basic/ngram-contains-panic.aql ---------------------------------------------------------------------- diff --git a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/inverted-index-basic/ngram-contains-panic.aql b/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/inverted-index-basic/ngram-contains-panic.aql deleted file mode 100644 index 842f7af..0000000 --- a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/inverted-index-basic/ngram-contains-panic.aql +++ /dev/null @@ -1,46 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - */ -/* - * Description : Tests whether an ngram_index is applied to optimize a selection query using the contains function. - * The index should *not* be applied (see below). - * Success : Yes - */ - -drop dataverse test if exists; -create dataverse test; -use dataverse test; - -create type DBLPType as open { - id: int32, - dblpid: string, - authors: string, - misc: string -} - -create dataset DBLP(DBLPType) primary key id; - -create index ngram_index on DBLP(title:string?) type ngram(3) enforced; - -write output to asterix_nc1:"rttest/inverted-index-basic_ngram-contains-panic.adm"; - -// Cannot optimize this query because the string constant is shorter than the gram length. -for $o in dataset('DBLP') -where contains($o.title, "Mu") -order by $o.id -return $o http://git-wip-us.apache.org/repos/asf/asterixdb/blob/f372c96d/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/inverted-index-basic/ngram-contains.aql ---------------------------------------------------------------------- diff --git a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/inverted-index-basic/ngram-contains.aql b/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/inverted-index-basic/ngram-contains.aql deleted file mode 100644 index f5aa09f..0000000 --- a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/inverted-index-basic/ngram-contains.aql +++ /dev/null @@ -1,45 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - */ -/* - * Description : Tests whether an ngram_index is applied to optimize a selection query using the contains function. - * The index should be applied. - * Success : Yes - */ - -drop dataverse test if exists; -create dataverse test; -use dataverse test; - -create type DBLPType as open { - id: int32, - dblpid: string, - authors: string, - misc: string -} - -create dataset DBLP(DBLPType) primary key id; - -create index ngram_index on DBLP(title:string?) type ngram(3) enforced; - -write output to asterix_nc1:"rttest/inverted-index-basic_ngram-contains.adm"; - -for $o in dataset('DBLP') -where contains($o.title, "Multimedia") -order by $o.id -return $o http://git-wip-us.apache.org/repos/asf/asterixdb/blob/f372c96d/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/inverted-index-basic/ngram-edit-distance-check.aql ---------------------------------------------------------------------- diff --git a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/inverted-index-basic/ngram-edit-distance-check.aql b/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/inverted-index-basic/ngram-edit-distance-check.aql deleted file mode 100644 index 78ab408..0000000 --- a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/inverted-index-basic/ngram-edit-distance-check.aql +++ /dev/null @@ -1,44 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - */ -/* - * Description : Tests whether an ngram_index is applied to optimize a selection query using the edit-distance-check function on strings. - * The index should be applied. - * Success : Yes - */ - -drop dataverse test if exists; -create dataverse test; -use dataverse test; - -create type DBLPType as open { - id: int32, - dblpid: string, - title: string, - misc: string -} - -create dataset DBLP(DBLPType) primary key id; - -create index ngram_index on DBLP(authors:string?) type ngram(3) enforced; - -write output to asterix_nc1:"rttest/inverted-index-basic_ngram-edit-distance-check.adm"; - -for $o in dataset('DBLP') -where edit-distance-check($o.authors, "Amihay Motro", 1)[0] -return $o http://git-wip-us.apache.org/repos/asf/asterixdb/blob/f372c96d/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/inverted-index-basic/ngram-edit-distance.aql ---------------------------------------------------------------------- diff --git a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/inverted-index-basic/ngram-edit-distance.aql b/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/inverted-index-basic/ngram-edit-distance.aql deleted file mode 100644 index e88bdc8..0000000 --- a/asterixdb/asterix-app/src/test/resources/optimizerts/queries/open-index-enforced/inverted-index-basic/ngram-edit-distance.aql +++ /dev/null @@ -1,44 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - */ -/* - * Description : Tests whether an ngram_index is applied to optimize a selection query using the edit-distance function on strings. - * The index should be applied. - * Success : Yes - */ - -drop dataverse test if exists; -create dataverse test; -use dataverse test; - -create type DBLPType as open { - id: int32, - dblpid: string, - title: string, - misc: string -} - -create dataset DBLP(DBLPType) primary key id; - -create index ngram_index on DBLP(authors:string?) type ngram(3) enforced; - -write output to asterix_nc1:"rttest/inverted-index-basic_ngram-edit-distance.adm"; - -for $o in dataset('DBLP') -where edit-distance($o.authors, "Amihay Motro") <= 1 -return $o
