SQLite Forum

FTS build docs inconsistency
Login
[https://sqlite.org/fts3.html#compiling_and_enabling_fts3_and_fts4] says:

  Note that enabling FTS3 also makes FTS4 available. There is not a separate <code>SQLITE_ENABLE_FTS4</code> compile-time option. A build of SQLite either supports both FTS3 and FTS4 or it supports neither.

But [https://sqlite.org/compile.html#_options_to_enable_features_normally_turned_off] defines both <code>SQLITE_ENABLE_FTS3</code> and <code>SQLITE_ENABLE_FTS4</code>, and the FTS4 macro doc mentions adding both versions to the build, while the FTS3 macro doc only mentions version 3.

And from the amalgamation:
<pre>
/*
** FTS4 is really an extension for FTS3.  It is enabled using the
** SQLITE_ENABLE_FTS3 macro.  But to avoid confusion we also all
** the SQLITE_ENABLE_FTS4 macro to serve as an alisse for SQLITE_ENABLE_FTS3.
*/
</pre>

I don't use FTS myself, but I'll assume that the two compile-time options in fact enable exactly the same functionality, so can I suggest the following edits for clarity?

[https://sqlite.org/fts3.html#compiling_and_enabling_fts3_and_fts4]:

  Note that enabling FTS3 also makes FTS4 available. <strike>There is not a separate <code>SQLITE_ENABLE_FTS4</code> compile-time option.</strike> A build of SQLite either supports both FTS3 and FTS4 or it supports neither.

[https://sqlite.org/compile.html#_options_to_enable_features_normally_turned_off]:

<b>SQLITE_ENABLE_FTS3</b>

  When this option is defined in the amalgamation, versions 3 and 4 of the full-text search engine is added to the build automatically.

<b>SQLITE_ENABLE_FTS4</b>

  This is an alias for <code>SQLITE_ENABLE_FTS3</code>.