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:d...@sqlite.org>
Sent: 08 February 2017 16:36
To: SQLite mailing list<mailto:sqlite-users@mailinglists.sqlite.org>
Subject: Re: [sqlite] sqlite3_complete



On 2/8/17, Richard Hipp <d...@sqlite.org> wrote:
> On 2/8/17, x <tam118...@hotmail.com> 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
d...@sqlite.org
_______________________________________________
sqlite-users mailing list
sqlite-users@mailinglists.sqlite.org
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users
_______________________________________________
sqlite-users mailing list
sqlite-users@mailinglists.sqlite.org
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to