salsubaiee | bb16791 | 2013-12-21 12:55:52 -0800 | [diff] [blame] | 1 | /* |
| 2 | * Description : Notice the query hint to avoid using any secondary index to evaluate the predicate in the where clause |
| 3 | * Expected Res : Success |
| 4 | * Date : 21th December 2013 |
| 5 | */ |
| 6 | |
| 7 | drop dataverse test if exists; |
| 8 | create dataverse test; |
| 9 | use dataverse test; |
| 10 | |
| 11 | create type DBLPType as closed { |
| 12 | id: int32, |
| 13 | dblpid: string, |
| 14 | title: string, |
| 15 | authors: string, |
| 16 | misc: string |
| 17 | } |
| 18 | |
| 19 | create dataset DBLP(DBLPType) primary key id; |
| 20 | |
| 21 | create index ngram_index on DBLP(title) type ngram(3); |
| 22 | |
| 23 | write output to nc1:"rttest/inverted-index-basic_ngram-contains.adm"; |
| 24 | |
| 25 | for $o in dataset('DBLP') |
salsubaiee | df89fbc | 2013-12-21 19:51:42 -0800 | [diff] [blame] | 26 | where /*+ skip-index */ contains($o.title, "Multimedia") |
salsubaiee | bb16791 | 2013-12-21 12:55:52 -0800 | [diff] [blame] | 27 | order by $o.id |
| 28 | return $o |