On 18 Apr 2014, at 3:21pm, Dominique Devienne <ddevie...@gmail.com> wrote:

> On Fri, Apr 18, 2014 at 12:53 AM, Simon Slavin <slav...@bigfraud.org> wrote:
>> There are ways to enforce field length limits entirely within SQLite but 
>> they're complicated so post again if you want me to explain TRIGGERs.
> 
> No need to resort to triggers. A simple check constraint will do

A constraint can prevent you from putting too-long values in the field.  A 
trigger can truncate the value to the correct length, which is what declaring a 
column as VARCHAR() would do.

Simon.
_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to