>> The receiving field is defined as CHAR; [snip]
> SQLite has no such type.  Define the fields as TEXT instead:

Simon, please don't confuse poor users. SQLite will work perfectly and
indistinguishably well with both CHAR and TEXT. Please read the link
you gave more carefully (hint: bullet number 2 in the section 2.1).

> Then try 'UPDATE UPCs SET UPC=043000205563;' and see what you get.

And your propose is nothing better than original one. The problem is
you both are trying to insert into text field a number. Leading zeros
in the number can never be significant, so they are trimmed before
this number is converted to text. The solution is to put single quotes
around anything that supposed to be treated as text.


Pavel

On Tue, Jul 6, 2010 at 6:17 PM, Simon Slavin <slav...@bigfraud.org> wrote:
>
> On 6 Jul 2010, at 11:10pm, Ted Rolle, Jr. wrote:
>
>> The receiving field is defined as CHAR; [snip]
>
> SQLite has no such type.  Define the fields as TEXT instead:
>
> <http://www.sqlite.org/datatype3.html>
>
> Then try 'UPDATE UPCs SET UPC=043000205563;' and see what you get.
>
>> Last question: is this an example of SQLite's "typelessness"?
>
> SQLite has types.  It just doesn't require every value in the same column to 
> be of the same type.
>
> Simon.
> _______________________________________________
> sqlite-users mailing list
> sqlite-users@sqlite.org
> http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
>
_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to