/ Check-in [d584a0cb]
Login

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

Overview
Comment:In order to avoid exporting a symbol, use a macro instead of a function to replace sqlite3_complete() in the shell code when SQLITE_OMIT_COMPLETE is defined.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA3-256: d584a0cb512815945ef06ee3b5ebadbf2a543b008487f6d098e1e8ab79f61d2d
User & Date: dan 2018-11-16 14:36:42
Context
2018-11-16
15:08
Update the generate_series() table-valued function to make use of the new SQLITE_CONSTRAINT return from xBestIndex. check-in: 4372ad64 user: drh tags: trunk
14:36
In order to avoid exporting a symbol, use a macro instead of a function to replace sqlite3_complete() in the shell code when SQLITE_OMIT_COMPLETE is defined. check-in: d584a0cb user: dan tags: trunk
13:56
Enhance the xBestIndex interface of virtual table so that if the xBestIndex method returns SQLITE_CONSTRAINT then that particular combination of constraints is considered unusable and does not participate further in query planning. check-in: 684013ce user: drh tags: trunk
Changes
Hide Diffs Side-by-Side Diffs Ignore Whitespace Patch

Changes to src/shell.c.in.

  8061   8061   /*
  8062   8062   ** We need a default sqlite3_complete() implementation to use in case
  8063   8063   ** the shell is compiled with SQLITE_OMIT_COMPLETE.  The default assumes
  8064   8064   ** any arbitrary text is a complete SQL statement.  This is not very
  8065   8065   ** user-friendly, but it does seem to work.
  8066   8066   */
  8067   8067   #ifdef SQLITE_OMIT_COMPLETE
  8068         -int sqlite3_complete(const char *zSql){ return 1; }
         8068  +#define sqlite3_complete(x) 1
  8069   8069   #endif
  8070   8070   
  8071   8071   /*
  8072   8072   ** Return true if zSql is a complete SQL statement.  Return false if it
  8073   8073   ** ends in the middle of a string literal or C-style comment.
  8074   8074   */
  8075   8075   static int line_is_complete(char *zSql, int nSql){