SQLite

Check-in [4bee8295e3]
Login

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

Overview
Comment:Simplifications to the description of the nByte parameter to sqlite3_prepare() and friends.
Downloads: Tarball | ZIP archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: 4bee8295e36fb61f903210b6d052ee9b8fb3b6d0
User & Date: drh 2015-02-26 02:33:52.248
Context
2015-02-26
16:32
Fix a real bug (in test code) that was introduced while trying to eliminate harmless compiler warnings from OpenBSD (see check-in [10321910990195878c]). (check-in: a62ba58c73 user: drh tags: trunk)
14:27
In the command-line shell, change the units on the ".width" directive from bytes to characters. (Leaf check-in: b1a9e2916f user: drh tags: cli-char-width)
02:33
Simplifications to the description of the nByte parameter to sqlite3_prepare() and friends. (check-in: 4bee8295e3 user: drh tags: trunk)
2015-02-25
14:25
Make sure the sqlite3_mutex.id field is initialized in the Win32 mutex implementation, even when SQLITE_DEBUG is turned off. (check-in: 6d132e7a22 user: drh tags: trunk)
Changes
Side-by-Side Diff Ignore Whitespace Patch
Changes to src/sqlite.h.in.
3178
3179
3180
3181
3182
3183
3184
3185
3186
3187
3188




3189
3190
3191
3192
3193




3194
3195
3196
3197
3198
3199
3200
3201
3178
3179
3180
3181
3182
3183
3184




3185
3186
3187
3188





3189
3190
3191
3192

3193
3194
3195
3196
3197
3198
3199







-
-
-
-
+
+
+
+
-
-
-
-
-
+
+
+
+
-







** [sqlite3_open16()].  The database connection must not have been closed.
**
** The second argument, "zSql", is the statement to be compiled, encoded
** as either UTF-8 or UTF-16.  The sqlite3_prepare() and sqlite3_prepare_v2()
** interfaces use UTF-8, and sqlite3_prepare16() and sqlite3_prepare16_v2()
** use UTF-16.
**
** ^If the nByte argument is less than zero, then zSql is read up to the
** first zero terminator. ^If nByte is non-negative, then it is the maximum
** number of  bytes read from zSql.  ^When nByte is non-negative, the
** zSql string ends at either the first '\000' or '\u0000' character or
** ^If the nByte argument is negative, then zSql is read up to the
** first zero terminator. ^If nByte is positive, then it is the
** number of bytes read from zSql.  ^If nByte is zero, then no prepared
** statement is generated.
** the nByte-th byte, whichever comes first. If the caller knows
** that the supplied string is nul-terminated, then there is a small
** performance advantage to be gained by passing an nByte parameter that
** is equal to the number of bytes in the input string <i>including</i>
** the nul-terminator bytes as this saves SQLite from having to
** If the caller knows that the supplied string is nul-terminated, then
** there is a small performance advantage to passing an nByte parameter that
** is the number of bytes in the input string <i>including</i>
** the nul-terminator.
** make a copy of the input string.
**
** ^If pzTail is not NULL then *pzTail is made to point to the first byte
** past the end of the first SQL statement in zSql.  These routines only
** compile the first statement in zSql, so *pzTail is left pointing to
** what remains uncompiled.
**
** ^*ppStmt is left pointing to a compiled [prepared statement] that can be