OK, thanks Richard. When I first discovered the function I was hoping it would do more than it said on the tin.
Sent from Mail<https://go.microsoft.com/fwlink/?LinkId=550986> for Windows 10 From: Richard Hipp<mailto:[email protected]> Sent: 08 February 2017 16:36 To: SQLite mailing list<mailto:[email protected]> Subject: Re: [sqlite] sqlite3_complete On 2/8/17, Richard Hipp <[email protected]> wrote: > On 2/8/17, x <[email protected]> wrote: >> >> It checks the input is appended with a semi-colon? Surely I’m missing >> something? >> > > It also verifies that the semicolon at the end is not part of a > string, or comment, nor in the middle of a CREATE TRIGGER statement. Examples: sqlite3_complete("x;") -> true sqlite3_complete(" 'x; ") -> false sqlite3_complete(" 'x'; ") -> true sqltie3_complete(" /* x; ") -> false sqlite3_complete(" CREATE TRIGGER xyz blah blah; yada yada; ") -> false; sqlite3_complete(" CREATE TRIGGER xyz blah blah; END; ") -> true; -- D. Richard Hipp [email protected] _______________________________________________ sqlite-users mailing list [email protected] http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users _______________________________________________ sqlite-users mailing list [email protected] http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users

