2012/4/17 YAN HONG YE <yanhong...@mpsa.com>: > UPDATE bb SET Slevel = > CASE price1>12 WHEN 1 THEN 1 ELSE 0 END + > CASE price1>30 WHEN 1 THEN 1 ELSE 0 END + > CASE price2>20 WHEN 1 THEN 1 ELSE 0 END + > CASE price2>30 WHEN 1 THEN 1 ELSE 0 END + > case... > csse... > ... > CASE price2>80 WHEN 1 THEN 1 ELSE 0 END; > in this command, I don't know sqlite allow how much "case...when..." in one > sql command.
The maximum number of bytes in the text of an SQL statement is limited to SQLITE_MAX_SQL_LENGTH which defaults to 1000000. You can redefine this limit to be as large as the smaller of SQLITE_MAX_LENGTH and 1073741824. http://www.sqlite.org/limits.html -- Kit _______________________________________________ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users