/ Check-in [8e9b9553]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Fix the NEAR connector in FTS3 so that it can take ranges in excess of 9. The maximum range is now 32767. (CVS 5695)
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1:8e9b9553115c42dae38cad0612d98d9a0c453a5c
User & Date: drh 2008-09-12 18:25:31
Context
2008-09-13
01:20
Fix issues with bizarrely quoted column names. Tickets #3370, #3371, and #3372. (CVS 5696) check-in: ced6bbd2 user: drh tags: trunk
2008-09-12
18:25
Fix the NEAR connector in FTS3 so that it can take ranges in excess of 9. The maximum range is now 32767. (CVS 5695) check-in: 8e9b9553 user: drh tags: trunk
16:03
Declare the isInterrupted field of the sqlite3 structure to be volatile. Ticket #3369. (CVS 5694) check-in: 414da4eb user: drh tags: trunk
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to ext/fts3/fts3.c.

1820
1821
1822
1823
1824
1825
1826
1827
1828
1829
1830
1831
1832
1833
1834
....
3801
3802
3803
3804
3805
3806
3807
3808
3809
3810
3811
3812
3813
3814
3815
3816
3817
3818
3819
3820
3821
3822
3823
3824
3825
3826
3827
3828
3829
3830
3831
3832
3833
3834
3835
3836
3837
3838
3839
3840
3841
3842
3843
3844
3845
3846
3847
3848
3849
3850
3851
3852
3853
3854
3855
3856
3857
3858
3859
3860
3861
3862
3863
3864

3865
3866
3867
3868
3869
3870
3871
3872
3873
3874
3875
3876
3877
3878
3879
3880
3881
3882
3883
3884
3885
3886
3887
3888
3889
3890
** compiling the FTS3 syntax to Query structures is done by the parseQuery()
** function.
*/
typedef struct QueryTerm {
  short int nPhrase; /* How many following terms are part of the same phrase */
  short int iPhrase; /* This is the i-th term of a phrase. */
  short int iColumn; /* Column of the index that must match this term */
  signed char nNear; /* term followed by a NEAR operator with span=(nNear-1) */
  signed char isOr;  /* this term is preceded by "OR" */
  signed char isNot; /* this term is preceded by "-" */
  signed char isPrefix; /* this term is followed by "*" */
  char *pTerm;       /* text of the term.  '\000' terminated.  malloced */
  int nTerm;         /* Number of bytes in pTerm[] */
} QueryTerm;

................................................................................
      return i;
    }
  }
  return -1;
}

/*
** Parse the text at pSegment[0..nSegment-1].  Add additional terms
** to the query being assemblied in pQuery.
**
** inPhrase is true if pSegment[0..nSegement-1] is contained within
** double-quotes.  If inPhrase is true, then the first term
** is marked with the number of terms in the phrase less one and
** OR and "-" syntax is ignored.  If inPhrase is false, then every
** term found is marked with nPhrase=0 and OR and "-" syntax is significant.
*/
static int tokenizeSegment(
  sqlite3_tokenizer *pTokenizer,          /* The tokenizer to use */
  const char *pSegment, int nSegment,     /* Query expression being parsed */
  int inPhrase,                           /* True if within "..." */
  Query *pQuery                           /* Append results here */
){
  const sqlite3_tokenizer_module *pModule = pTokenizer->pModule;
  sqlite3_tokenizer_cursor *pCursor;
  int firstIndex = pQuery->nTerms;
  int iCol;
  int nTerm = 1;
  
  int rc = pModule->xOpen(pTokenizer, pSegment, nSegment, &pCursor);
  if( rc!=SQLITE_OK ) return rc;
  pCursor->pTokenizer = pTokenizer;

  while( 1 ){
    const char *pToken;
    int nToken, iBegin, iEnd, iPos;

    rc = pModule->xNext(pCursor,
                        &pToken, &nToken,
                        &iBegin, &iEnd, &iPos);
    if( rc!=SQLITE_OK ) break;
    if( !inPhrase &&
        pSegment[iEnd]==':' &&
         (iCol = checkColumnSpecifier(pQuery->pFts, pToken, nToken))>=0 ){
      pQuery->nextColumn = iCol;
      continue;
    }
    if( !inPhrase && pQuery->nTerms>0 && nToken==2 
     && pSegment[iBegin+0]=='O'
     && pSegment[iBegin+1]=='R' 
    ){
      pQuery->nextIsOr = 1;
      continue;
    }
    if( !inPhrase && pQuery->nTerms>0 && !pQuery->nextIsOr && nToken==4 
      && pSegment[iBegin+0]=='N' 
      && pSegment[iBegin+1]=='E' 
      && pSegment[iBegin+2]=='A' 
      && pSegment[iBegin+3]=='R' 
    ){
      QueryTerm *pTerm = &pQuery->pTerms[pQuery->nTerms-1];
      if( (iBegin+6)<nSegment 
       && pSegment[iBegin+4] == '/'
       && pSegment[iBegin+5]>='0' && pSegment[iBegin+5]<='9'
      ){

        pTerm->nNear = (pSegment[iBegin+5] - '0');
        nToken += 2;
        if( pSegment[iBegin+6]>='0' && pSegment[iBegin+6]<=9 ){
          pTerm->nNear = pTerm->nNear * 10 + (pSegment[iBegin+6] - '0');
          iEnd++;
        }
        pModule->xNext(pCursor, &pToken, &nToken, &iBegin, &iEnd, &iPos);
      } else {
        pTerm->nNear = SQLITE_FTS3_DEFAULT_NEAR_PARAM;
      }
      pTerm->nNear++;
      continue;
    }

    queryAdd(pQuery, pToken, nToken);
    if( !inPhrase && iBegin>0 && pSegment[iBegin-1]=='-' ){
      pQuery->pTerms[pQuery->nTerms-1].isNot = 1;
    }
    if( iEnd<nSegment && pSegment[iEnd]=='*' ){
      pQuery->pTerms[pQuery->nTerms-1].isPrefix = 1;
    }
    pQuery->pTerms[pQuery->nTerms-1].iPhrase = nTerm;
    if( inPhrase ){
      nTerm++;
    }
  }







|







 







|


|







|









|




|



|



|
|




|
|





|
<
<
<



|
|

>
|
<
|
|
<

|







|
|


|







1820
1821
1822
1823
1824
1825
1826
1827
1828
1829
1830
1831
1832
1833
1834
....
3801
3802
3803
3804
3805
3806
3807
3808
3809
3810
3811
3812
3813
3814
3815
3816
3817
3818
3819
3820
3821
3822
3823
3824
3825
3826
3827
3828
3829
3830
3831
3832
3833
3834
3835
3836
3837
3838
3839
3840
3841
3842
3843
3844
3845
3846
3847
3848
3849
3850
3851
3852
3853
3854
3855



3856
3857
3858
3859
3860
3861
3862
3863

3864
3865

3866
3867
3868
3869
3870
3871
3872
3873
3874
3875
3876
3877
3878
3879
3880
3881
3882
3883
3884
3885
3886
** compiling the FTS3 syntax to Query structures is done by the parseQuery()
** function.
*/
typedef struct QueryTerm {
  short int nPhrase; /* How many following terms are part of the same phrase */
  short int iPhrase; /* This is the i-th term of a phrase. */
  short int iColumn; /* Column of the index that must match this term */
  short int nNear;   /* term followed by a NEAR operator with span=(nNear-1) */
  signed char isOr;  /* this term is preceded by "OR" */
  signed char isNot; /* this term is preceded by "-" */
  signed char isPrefix; /* this term is followed by "*" */
  char *pTerm;       /* text of the term.  '\000' terminated.  malloced */
  int nTerm;         /* Number of bytes in pTerm[] */
} QueryTerm;

................................................................................
      return i;
    }
  }
  return -1;
}

/*
** Parse the text at zSegment[0..nSegment-1].  Add additional terms
** to the query being assemblied in pQuery.
**
** inPhrase is true if zSegment[0..nSegement-1] is contained within
** double-quotes.  If inPhrase is true, then the first term
** is marked with the number of terms in the phrase less one and
** OR and "-" syntax is ignored.  If inPhrase is false, then every
** term found is marked with nPhrase=0 and OR and "-" syntax is significant.
*/
static int tokenizeSegment(
  sqlite3_tokenizer *pTokenizer,          /* The tokenizer to use */
  const char *zSegment, int nSegment,     /* Query expression being parsed */
  int inPhrase,                           /* True if within "..." */
  Query *pQuery                           /* Append results here */
){
  const sqlite3_tokenizer_module *pModule = pTokenizer->pModule;
  sqlite3_tokenizer_cursor *pCursor;
  int firstIndex = pQuery->nTerms;
  int iCol;
  int nTerm = 1;
  
  int rc = pModule->xOpen(pTokenizer, zSegment, nSegment, &pCursor);
  if( rc!=SQLITE_OK ) return rc;
  pCursor->pTokenizer = pTokenizer;

  while( 1 ){
    const char *zToken;
    int nToken, iBegin, iEnd, iPos;

    rc = pModule->xNext(pCursor,
                        &zToken, &nToken,
                        &iBegin, &iEnd, &iPos);
    if( rc!=SQLITE_OK ) break;
    if( !inPhrase &&
        zSegment[iEnd]==':' &&
         (iCol = checkColumnSpecifier(pQuery->pFts, zToken, nToken))>=0 ){
      pQuery->nextColumn = iCol;
      continue;
    }
    if( !inPhrase && pQuery->nTerms>0 && nToken==2 
     && zSegment[iBegin+0]=='O'
     && zSegment[iBegin+1]=='R' 
    ){
      pQuery->nextIsOr = 1;
      continue;
    }
    if( !inPhrase && pQuery->nTerms>0 && !pQuery->nextIsOr && nToken==4 
      && memcmp(&zSegment[iBegin], "NEAR", 4)==0



    ){
      QueryTerm *pTerm = &pQuery->pTerms[pQuery->nTerms-1];
      if( (iBegin+6)<nSegment 
       && zSegment[iBegin+4] == '/'
       && isdigit(zSegment[iBegin+5])
      ){
        int k;
        pTerm->nNear = 0;

        for(k=5; (iBegin+k)<=nSegment && isdigit(zSegment[iBegin+k]); k++){
          pTerm->nNear = pTerm->nNear*10 + (zSegment[iBegin+k] - '0');

        }
        pModule->xNext(pCursor, &zToken, &nToken, &iBegin, &iEnd, &iPos);
      } else {
        pTerm->nNear = SQLITE_FTS3_DEFAULT_NEAR_PARAM;
      }
      pTerm->nNear++;
      continue;
    }

    queryAdd(pQuery, zToken, nToken);
    if( !inPhrase && iBegin>0 && zSegment[iBegin-1]=='-' ){
      pQuery->pTerms[pQuery->nTerms-1].isNot = 1;
    }
    if( iEnd<nSegment && zSegment[iEnd]=='*' ){
      pQuery->pTerms[pQuery->nTerms-1].isPrefix = 1;
    }
    pQuery->pTerms[pQuery->nTerms-1].iPhrase = nTerm;
    if( inPhrase ){
      nTerm++;
    }
  }

Changes to test/fts3near.test.

6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
...
160
161
162
163
164
165
166
167













































































































































































































































































































































































































168
#
#    May you do good and not evil.
#    May you find forgiveness for yourself and forgive others.
#    May you share freely, never taking more than you give.
#
#*************************************************************************
#
# $Id: fts3near.test,v 1.1 2007/10/22 18:02:20 danielk1977 Exp $
#

set testdir [file dirname $argv0]
source $testdir/tester.tcl

# If SQLITE_ENABLE_FTS3 is defined, omit this file.
ifcapable !fts3 {
................................................................................
  ') 
}
do_test fts3near-4.1 {
  execsql {
    SELECT snippet(t1) FROM t1 WHERE content MATCH 'specification NEAR supports'
  }
} {{<b>...</b> devices, handheld devices, etc. This <b>specification</b> also <b>supports</b> content positioning, downloadable fonts, <b>...</b>}}














































































































































































































































































































































































































finish_test







|







 








>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>

6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
...
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
#
#    May you do good and not evil.
#    May you find forgiveness for yourself and forgive others.
#    May you share freely, never taking more than you give.
#
#*************************************************************************
#
# $Id: fts3near.test,v 1.2 2008/09/12 18:25:31 drh Exp $
#

set testdir [file dirname $argv0]
source $testdir/tester.tcl

# If SQLITE_ENABLE_FTS3 is defined, omit this file.
ifcapable !fts3 {
................................................................................
  ') 
}
do_test fts3near-4.1 {
  execsql {
    SELECT snippet(t1) FROM t1 WHERE content MATCH 'specification NEAR supports'
  }
} {{<b>...</b> devices, handheld devices, etc. This <b>specification</b> also <b>supports</b> content positioning, downloadable fonts, <b>...</b>}}

do_test fts3near-5.1 {
  execsql {
    SELECT docid FROM t1 WHERE content MATCH 'specification attach'
  }
} {2}
do_test fts3near-5.2 {
  execsql {
    SELECT docid FROM t1 WHERE content MATCH 'specification NEAR attach'
  }
} {}
do_test fts3near-5.3 {
  execsql {
    SELECT docid FROM t1 WHERE content MATCH 'specification NEAR/18 attach'
  }
} {}
do_test fts3near-5.4 {
  execsql {
    SELECT docid FROM t1 WHERE content MATCH 'specification NEAR/19 attach'
  }
} {2}
do_test fts3near-5.5 {
  execsql {
    SELECT docid FROM t1 WHERE content MATCH 'specification NEAR/000018 attach'
  }
} {}
do_test fts3near-5.6 {
  execsql {
    SELECT docid FROM t1 WHERE content MATCH 'specification NEAR/000019 attach'
  }
} {2}

db eval {
  INSERT INTO t1 VALUES('
      abbrev aberrations abjurations aboding abr abscesses absolutistic
      abstention abuses acanthuses acceptance acclaimers accomplish
      accoutring accusation acetonic acid acolytes acquitting acrylonitrile
      actives acyclic addicted adenoid adjacently adjusting admissible
      adoption adulated advantaging advertisers aedes aerogramme aetiology
      affiliative afforest afterclap agamogenesis aggrade agings agonize
      agron ailurophile airfreight airspeed alarmists alchemizing
      alexandrines alien aliped all allergenic allocator allowances almost
      alphabetizes altho alvine amaurosis ambles ameliorate amicability amnio
      amour ampicillin amusement anadromous analogues anarchy anchormen
      anecdota aneurin angst animating anlage announcements anodized
      answerable antemeridian anthracene antiabortionist anticlimaxes
      antifriction antimitotic antiphon antiques antithetic anviled
      apatosaurus aphrodisia apodal aposiopesis apparatus appendectomies
      applications appraisingly appropriate apteryx arabinose
      arboricultural archdeaconates archipelago ardently arguers armadillo
      arnicas arrayed arrowy arthroscope artisans ascensive ashier
      aspersorium assail assentor assignees assonants astereognosis
      astringency astutest atheistical atomize attachment attenuates
      attrahent audibility augite auricle auteurists autobus autolysis
      autosome avenge avidest aw awl ayes babirusa backbeats backgrounder
      backseat backswings baddie bagnios baked balefuller ballista balmily
      bandbox bandylegged bankruptcy baptism barbering bargain barneys
      barracuda barterer bashes bassists bathers batterer bavardage
      beachfront beanstalk beauteous become bedim bedtimes beermats begat
      begun belabors bellarmine belongings bending benthos bereavements
      besieger bestialized betide bevels biases bicarbonates bidentate bigger
      bile billow bine biodynamics biomedicine biotites birding bisection
      bitingly bkg blackheads blaeberry blanking blatherer bleeper blindage
      blithefulness blockish bloodstreams bloused blubbing bluestocking
      blurted boatbill bobtailed boffo bold boltrope bondservant bonks
      bookbinding bookworm booting borating boscages botchers bougainvillea
      bounty bowlegged boyhood bracketed brainstorm brandishes
      braunschweigers brazilin breakneck breathlessness brewage bridesmaids
      brighter brisker broader brokerages bronziest browband brunets bryology
      bucking budlike bugleweed bulkily bulling bummer bunglers bureau burgs
      burrito bushfire buss butlery buttressing bylines cabdriver cached
      cadaverousnesses cafeterias cakewalk calcifies calendula callboy calms
      calyptra camisoles camps candelabrum caned cannolis canoodling cantors
      cape caponize capsuling caracoled carbolics carcase carditis caretakers
      carnallite carousel carrageenan cartels carves cashbook castanets
      casuistry catalyzer catchers categorizations cathexis caucuses
      causeway cavetto cede cella cementite centenary centrals ceramics ceria
      cervixes chafferer chalcopyrites chamfers change chaotically
      characteristically charivari chases chatterer cheats cheeks chef
      chemurgy chetah chickaree chigoes chillies chinning chirp chive
      chloroforms chokebore choplogic chorioids chromatic chronically
      chubbiest chunder chutzpah cimetidine cinque circulated circumscribe
      cirrose citrin claddagh clamorousness clapperboards classicalism
      clauses cleanse clemency clicker clinchers cliquiest clods closeting
      cloudscape clucking cnidarian coalfish coatrack coca cockfights coddled
      coeducation coexistence cognitively coiffed colatitude collage
      collections collinear colonelcy colorimetric columelliform combos
      comforters commence commercialist commit commorancy communized compar
      compendiously complainers compliance composition comprised comradery
      concelebrants concerted conciliation concourses condensate
      condonations confab confessionals confirmed conforming congeal
      congregant conjectured conjurers connoisseurs conscripting
      conservator consolable conspired constricting consuls contagious
      contemporaneity contesters continuities contractors contrarian
      contrive convalescents convents convexly convulsed cooncan coparcenary
      coprolite copyreader cordially corklike cornflour coroner corralling
      corrigible corsages cosies cosmonauts costumer cottontails counselings
      counterclaim counterpane countertenors courageously couth coveting
      coworker cozier cracklings crampon crappies craved cream credenzas
      crematoriums cresol cricoid crinkle criterion crocodile crore crossover
      crowded cruelest crunch cruzeiros cryptomeria cubism cuesta culprit
      cumquat cupped curdle curly cursoring curvy customized cutting cyclamens
      cylindrical cytaster dachshund daikon damages damselfly dangling
      darkest databanks dauphine dazzling deadpanned deathday debauchers
      debunking decameter decedents decibel decisions declinations
      decomposition decoratively decretive deduct deescalated defecating
      deferentially definiendum defluxion defrocks degrade deice dekaliters
      deli delinquencies deludedly demarcates demineralizers demodulating
      demonstrabilities demurred deniabilities denouncement denudation
      departure deplorable deposing depredatory deputizes derivational
      desalinization descriptors desexes desisted despising destitute
      detectability determiner detoxifying devalued devilries devotions
      dextrous diagenesis dialling diaphoresis diazonium dickeys diddums
      differencing dig dignified dildo dimetric dineric dinosaurs diplodocus
      directer dirty disagrees disassembler disburses disclosures
      disconcerts discountability discrete disembarrass disenthrone
      disgruntled dishpans disintegrators dislodged disobedient
      dispassionate dispiritednesses dispraised disqualifying
      dissatisfying dissidence dissolvers distich distracting distrusts
      ditto diverse divineness dizzily dockyard dodgers doggish doited dom
      dominium doohickey doozie dorsum doubleheaders dourer downbeats
      downshifted doyennes draftsman dramatic drawling dredge drifter
      drivelines droopier drowsed drunkards dubiosities duding dulcifying
      dumpcart duodecillion durable duteous dyed dysgenic eagles earplugs
      earwitness ebonite echoers economical ectothermous edibility educates
      effected effigies eggbeaters egresses ejaculates elasticize elector
      electrodynamometer electrophorus elem eligibly eloped emaciating
      embarcaderos embezzlers embosses embryectomy emfs emotionalizing
      empiricist emu enamels enchained encoded encrusts endeavored endogamous
      endothelioma energizes engager engrosses enl enologist enrolls ensphere
      enters entirety entrap entryways envies eosinophil epicentral
      epigrammatized episodic epochs equestrian equitably erect ernes
      errorless escalated eschatology espaliers essonite estop eternity
      ethnologically eudemonics euphonious euthenist evangelizations
      eventuality evilest evulsion examinee exceptionably exciter
      excremental execrably exemplars exhalant exhorter exocrine exothermic
      expected expends explainable exploratory expostulatory expunges
      extends externals extorts extrapolative extrorse eyebolt eyra
      facetiously factor faeries fairings fallacies falsities fancifulness
      fantasticalness farmhouse fascinate fatalistically fattener fave
      fearlessly featly federates feints fellowman fencers ferny
      fertilenesses feta feudality fibers fictionalize fiefs fightback
      filefish filmier finaglers fingerboards finochio firefly firmament
      fishmeal fitted fjords flagitiousnesses flamen flaps flatfooting
      flauntier fleapit fleshes flickertail flints floaty floorboards
      floristic flow fluffily fluorescein flutes flyspecks foetal folderols
      followable foolhardier footlockers foppish forceless foredo foreknows
      foreseeing foretaste forgather forlorn formidableness fortalice
      forwarding founding foxhunting fragmentarily frangipani fray freeform
      freezable freshening fridges frilliest frizzed frontbench frottages
      fruitcake fryable fugleman fulminated functionalists fungoid furfuran
      furtive fussy fwd gadolinium galabias gallinaceous galvanism gamers
      gangland gaoling garganey garrisoning gasp gate gauger gayety geed
      geminately generalissimos genii gentled geochronology geomorphic
      geriatricians gesellschaft ghat gibbeting giggles gimps girdlers
      glabella glaive glassfuls gleefully glistered globetrotted glorifier
      gloving glutathione glyptodont goaled gobsmacked goggliest golliwog
      goobers gooseberries gormandizer gouramis grabbier gradually grampuses
      grandmothers granulated graptolite gratuitously gravitates greaten
      greenmailer greys grills grippers groan gropingly grounding groveling
      grueled grunter guardroom guggle guineas gummed gunnysacks gushingly
      gutturals gynecoid gyrostabilizer habitudes haemophilia hailer hairs
      halest hallow halters hamsters handhelds handsaw hangup haranguer
      hardheartedness harlotry harps hashing hated hauntingly hayrack
      headcases headphone headword heartbreakers heaters hebephrenia
      hedonist heightening heliozoan helots hemelytron hemorrhagic hent
      herbicides hereunto heroines heteroclitics heterotrophs hexers
      hidebound hies hightails hindmost hippopotomonstrosesquipedalian
      histologist hittable hobbledehoys hogans holdings holocrine homegirls
      homesteader homogeneousness homopolar honeys hoodwinks hoovered
      horizontally horridness horseshoers hospitalization hotdogging houri
      housemate howitzers huffier humanist humid humors huntress husbandmen
      hyaenas hydride hydrokinetics hydroponically hygrothermograph
      hyperbolically hypersensitiveness hypnogogic hypodermically
      hypothermia iatrochemistry ichthyological idealist ideograms idling
      igniting illegal illuminatingly ilmenite imbibing immateriality
      immigrating immortalizes immures imparts impeder imperfection
      impersonated implant implying imposition imprecating imprimis
      improvising impv inanenesses inaugurate incapably incentivize
      incineration incloses incomparableness inconsequential incorporate
      incrementing incumbered indecorous indentation indicative indignities
      indistinguishably indoors indulges ineducation inerrable
      inexperienced infants infestations infirmnesses inflicting
      infracostal ingathered ingressions inheritances iniquity
      injuriousnesses innervated inoculates inquisitionist insectile
      insiders insolate inspirers instatement instr insulates intactness
      intellects intensifies intercalations intercontinental interferon
      interlarded intermarrying internalizing interpersonally
      interrelatednesses intersperse interviewees intolerance
      intransigents introducing intubates invades inventing inveterate
      invocate iodides irenicism ironsmith irreducibly irresistibility
      irriguous isobarisms isometrically issuable itineracies jackdaws
      jaggery jangling javelins jeeringly jeremiad jeweler jigsawing jitter
      jocosity jokester jot jowls judicative juicy jungly jurists juxtaposed
      kalpa karstify keddah kendo kermesses keynote kibbutznik kidnaper
      kilogram kindred kingpins kissers klatch kneads knobbed knowingest
      kookaburras kruller labefaction labyrinths lacquer laddered lagoons
      lambency laminates lancinate landscapist lankiness lapse larked lasso
      laterite laudableness laundrywomen lawgiver laypersons leafhoppers
      leapfrogs leaven leeches legated legislature leitmotifs lenients
      leprous letterheads levelling lexicographically liberalists
      librettist licorice lifesaving lightheadedly likelier limekiln limped
      lines linkers lipoma liquidator listeners litharge litmus
      liverishnesses loamier lobeline locative locutionary loggier loiterer
      longevity loomed loping lotion louts lowboys luaus lucrativeness lulus
      lumpier lungi lush luthern lymphangial lythraceous machinists maculate
      maggot magnetochemistry maharani maimers majored malaprops malignants
      maloti mammary manchineel manfully manicotti manipulativenesses
      mansards manufactories maraschino margin markdown marooning marshland
      mascaraing massaging masticate matchmark matings mattes mausoleum
      mayflies mealworm meataxe medevaced medievalist meetings megavitamin
      melded melodramatic memorableness mendaciousnesses mensurable
      mercenaries mere meronymous mesmerizes mestee metallurgical
      metastasize meterages meticulosity mewed microbe microcrystalline
      micromanager microsporophyll midiron miffed milder militiamen
      millesimal milometer mincing mingily minims minstrelsy mires
      misanthropic miscalculate miscomprehended misdefines misery mishears
      misled mispickel misrepresent misspending mistranslate miswriting
      mixologists mobilizers moderators modulate mojo mollies momentum monde
      monied monocles monographs monophyletic monotonousness moocher
      moorages morality morion mortally moseyed motherly motorboat mouldering
      mousers moveables mucky mudslides mulatto multicellularity
      multipartite multivalences mundanities murkiest mushed muskiness
      mutability mutisms mycelia myosotis mythicist nacred namable napkin
      narghile nastiness nattering nauseations nearliest necessitate
      necrophobia neg negotiators neologizes nephrotomy netiquette
      neurophysiology newbie newspaper niccolite nielsbohriums nightlong
      nincompoops nitpicked nix noddling nomadize nonadhesive noncandidates
      nonconducting nondigestible nones nongreasy nonjoinder nonoccurrence
      nonporousness nonrestrictive nonstaining nonuniform nooses northwards
      nostalgic notepaper nourishment noyades nuclides numberless numskulls
      nutmegged nymphaea oatmeal obis objurgators oblivious obsequiousness
      obsoletism obtruding occlusions ocher octettes odeums offcuts
      officiation ogival oilstone olestras omikron oncogenesis onsetting
      oomphs openly ophthalmoscope opposites optimum orangutans
      orchestrations ordn organophosphates origin ornithosis orthognathous
      oscillatory ossuaries ostracized ounce outbreaks outearning outgrows
      outlived outpoints outrunning outspends outwearing overabound
      overbalance overcautious overcrowds overdubbing overexpanding
      overgraze overindustrialize overlearning overoptimism overproducing
      overripe overshadowing overspreading overstuff overtones overwind ow
      oxidizing pacer packs paganish painstakingly palate palette pally
      palsying pandemic panhandled pantheism papaws papped parading
      parallelize paranoia parasitically pardners parietal parodied pars
      participator partridgeberry passerines password pastors
      paterfamiliases patination patrolman paunch pawnshops peacekeeper
      peatbog peculator pedestrianism peduncles pegboard pellucidnesses
      pendency penitentiary penstock pentylenetetrazol peptidase perched
      perennial performing perigynous peripheralize perjurer permissively
      perpetuals persistency perspicuously perturbingly pesky petcock
      petrologists pfennige pharmacies phenformin philanderers
      philosophically phonecards phosgenes photocomposer photogenic photons
      phototype phylloid physiotherapeutics picadores pickup pieces pigging
      pilaster pillion pimples pinioned pinpricks pipers pirogi pit
      pitifullest pizza placental plainly planing plasmin platforming
      playacts playwrights plectra pleurisy plopped plug plumule plussed
      poaches poetasters pointless polarize policyholder polkaed
      polyadelphous polygraphing polyphonous pomace ponderers pooch poplar
      porcelains portableness portly positioning postage posthumously
      postponed potages potholed poulard powdering practised pranksters
      preadapt preassigning precentors precipitous preconditions predefined
      predictors preengage prefers prehumans premedical prenotification
      preplanning prepuberty presbytery presentation presidia prestissimo
      preterites prevailer prewarmed priding primitively principalships
      prisage privileged probed prochurch proctoscope products proficients
      prognathism prohibiting proletarianisms prominence promulgates
      proofreading property proportions prorate proselytize prosthesis
      proteins prototypic provenances provitamin prudish pseudonymities
      psychoanalysts psychoneuroses psychrometer publishable pufferies
      pullet pulses punchy punkins purchased purities pursers pushover
      putridity pylons pyrogenous pzazz quadricepses quaff qualmish quarriers
      quasilinear queerness questionnaires quieten quintals quislings quoits
      rabidness racketeers radiative radioisotope radiotherapists ragingly
      rainband rakishness rampagers rands raped rare raspy ratiocinator
      rattlebrain ravening razz reactivation readoption realm reapportioning
      reasoning reattempts rebidding rebuts recapitulatory receptiveness
      recipes reckonings recognizee recommendatory reconciled reconnoiters
      recontaminated recoupments recruits recumbently redact redefine
      redheaded redistributable redraw redwing reeled reenlistment reexports
      refiles reflate reflowing refortified refried refuses regelate
      registrant regretting rehabilitative reigning reinduced reinstalled
      reinvesting rejoining relations relegates religiosities reluctivity
      remastered reminisce remodifying remounted rends renovate reordered
      repartee repel rephrase replicate repossessing reprint reprogramed
      repugnantly requiter rescheduling resegregate resettled residually
      resold resourcefulness respondent restating restrainedly resubmission
      resurveyed retaliating retiarius retorsion retreated retrofitting
      returning revanchism reverberated reverted revitalization
      revolutionize rewind rhapsodizing rhizogenic rhythms ricketinesses
      ridicule righteous rilles rinks rippliest ritualize riyals roast rockery
      roguish romanizations rookiest roquelaure rotation rotundity rounder
      routinizing rubberize rubricated ruefully ruining rummaged runic
      russets ruttish sackers sacrosanctly safeguarding said salaciousness
      salinity salsas salutatorians sampan sandbag saned santonin
      saprophagous sarnies satem saturant savaged sawbucks scablike scalp
      scant scared scatter schedulers schizophrenics schnauzers schoolmarms
      scintillae scleroses scoped scotched scram scratchiness screwball
      scripting scrubwomen scrutinizing scumbled scuttled seals seasickness
      seccos secretions secularizing seditiousnesses seeking segregators
      seize selfish semeiology seminarian semitropical sensate sensors
      sentimo septicemic sequentially serener serine serums
      sesquicentennials seventeen sexiest sforzandos shadowing shallot
      shampooing sharking shearer sheered shelters shifter shiner shipper
      shitted shoaled shofroth shorebirds shortsightedly showboated shrank
      shrines shucking shuttlecocks sickeningly sideling sidewise sigil
      signifiers siliceous silty simony simulative singled sinkings sirrah
      situps skateboarder sketchpad skim skirmished skulkers skywalk slander
      slating sleaziest sleepyheads slicking slink slitting slot slub
      slumlords smallest smattered smilier smokers smriti snailfish snatch
      snides snitching snooze snowblowers snub soapboxing socialite sockeyes
      softest sold solicitings solleret sombreros somnolencies sons sopor
      sorites soubrette soupspoon southpaw spaces spandex sparkers spatially
      speccing specking spectroscopists speedsters spermatics sphincter
      spiffied spindlings spirals spitball splayfeet splitter spokeswomen
      spooled sportily spousals sprightliness sprogs spurner squalene
      squattered squelches squirms stablish staggerings stalactitic stamp
      stands starflower starwort stations stayed steamroll steeplebush
      stemmatics stepfathers stereos steroid sticks stillage stinker
      stirringly stockpiling stomaching stopcock stormers strabismuses
      strainer strappado strawberries streetwise striae strikeouts strives
      stroppiest stubbed study stunting style suavity subchloride subdeb
      subfields subjoin sublittoral subnotebooks subprograms subside
      substantial subtenants subtreasuries succeeding sucked sufferers
      sugarier sulfaguanidine sulphating summerhouse sunbonnets sunned
      superagency supercontinent superheroes supernatural superscribing
      superthin supplest suppositive surcease surfs surprise survey
      suspiration svelte swamplands swashes sweatshop swellhead swindling
      switching sworn syllabuses sympathetics synchrocyclotron syndic
      synonymously syringed tablatures tabulation tackling taiga takas talker
      tamarisks tangential tans taproom tarpapers taskmaster tattiest
      tautologically taxied teacup tearjerkers technocracies teepee
      telegenic telephony telexed temperaments temptress tenderizing tensed
      tenuring tergal terned terror testatrices tetherball textile thatched
      their theorem thereof thermometers thewy thimerosal thirsty
      thoroughwort threateningly thrived through thumbnails thwacks
      ticketing tie til timekeepers timorousness tinkers tippers tisane
      titrating toastmaster toff toking tomb tongs toolmakings topes topple
      torose tortilla totalizing touchlines tousling townsmen trachea
      tradeable tragedienne traitorous trances transcendentalists
      transferrable tranship translating transmogrifying transportable
      transvestism traumatize treachery treed trenail tressing tribeswoman
      trichromatism triennials trikes trims triplicate tristich trivializes
      trombonist trots trouts trued trunnion tryster tubes tulle tundras turban
      turgescence turnround tutelar tweedinesses twill twit tympanum typists
      tzarists ulcered ultramodern umbles unaccountability unamended
      unassertivenesses unbanned unblocked unbundled uncertified unclaimed
      uncoated unconcerns unconvinced uncrossing undefined underbodice
      underemphasize undergrowth underpayment undershirts understudy
      underwritten undissolved unearthed unentered unexpended unfeeling
      unforeseen unfussy unhair unhinges unifilar unimproved uninvitingly
      universalization unknowns unlimbering unman unmet unnaturalness
      unornament unperturbed unprecedentedly unproportionate unread
      unreflecting unreproducible unripe unsatisfying unseaworthiness
      unsharable unsociable unstacking unsubtly untactfully untied untruest
      unveils unwilled unyokes upheave upraised upstart upwind urethrae
      urtexts usurers uvula vacillators vailed validation valvule vanities
      varia variously vassaled vav veggies velours venerator ventrals
      verbalizes verification vernacularized verticality vestigially via
      vicariously victoriousness viewpoint villainies vines violoncellist
      virtual viscus vital vitrify viviparous vocalizers voidable volleys
      volutes vouches vulcanology wackos waggery wainwrights waling wallowing
      wanking wardroom warmup wartiest washwoman watchman watermarks waverer
      wayzgoose weariest weatherstripped weediness weevil welcomed
      wentletrap whackers wheatworm whelp whf whinged whirl whistles whithers
      wholesomeness whosoever widows wikiup willowier windburned windsail
      wingspread winterkilled wisecracking witchgrass witling wobbliest
      womanliness woodcut woodworking woozy working worldwide worthiest
      wrappings wretched writhe wynd xylophone yardarm yea yelped yippee yoni
      yuks zealotry zigzagger zitherists zoologists zygosis');
}

do_test fts3near-6.1 {
  execsql {
    SELECT docid FROM t1 WHERE content MATCH 'abbrev zygosis'
  }
} {3}
do_test fts3near-6.2 {
  execsql {
    SELECT docid FROM t1 WHERE content MATCH 'abbrev NEAR zygosis'
  }
} {}
do_test fts3near-6.3 {
  execsql {
    SELECT docid FROM t1 WHERE content MATCH 'abbrev NEAR/100 zygosis'
  }
} {}
do_test fts3near-6.4 {
  execsql {
    SELECT docid FROM t1 WHERE content MATCH 'abbrev NEAR/1000 zygosis'
  }
} {}
do_test fts3near-6.5 {
  execsql {
    SELECT docid FROM t1 WHERE content MATCH 'abbrev NEAR/10000 zygosis'
  }
} {3}


finish_test