On Thu, Apr 12, 2012 at 2:06 PM, Zbigniew <zbigniew2...@gmail.com> wrote:

> At the attempt to get a non-existing value, for example:
>
> set x [dbcomm eval {SELECT max(somecolumn) FROM sometable}]
>

The correct way to do this would be one or other other of the following:

   set x [lindex [dbcomm eval {SELECT max(somecolumn) FROM sometable}]

   set x [dbcomm onecolumn eval {SELECT max(somecolumn) FROM sometable}]

In the second example, it is traditional to abbreviate "onecolumn" to
simply "one".


>
> The returned value of $x will be {} - and no, not "empty", but exactly
> these two characters.
>
> Easy to reproduce.
> --
> Zbigniew
> _______________________________________________
> sqlite-users mailing list
> sqlite-users@sqlite.org
> http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
>



-- 
D. Richard Hipp
d...@sqlite.org
_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to