Re: '001' -> '1' in Sqlite!!

2007-02-02 Thread Russell Keith-Magee
On 2/2/07, mamcxyz <[EMAIL PROTECTED]> wrote: > INSERT INTO Vendedor (Codigo) VALUES ('006') > > And blindly believe in the database. > > Then today I discover Sqlite "transform" it to '6'. That is I call a > shock! Specially when Sqlite declare that all the data is internally > stored as text. Y

Re: '001' -> '1' in Sqlite!!

2007-02-02 Thread Todd O'Bryan
Is the database field set up as a textual or numeric field? If it's textual, then this seems like a bug. If it's numeric, it seems perfectly reasonable and I would suggest changing any fields where you want leading zeroes to something that holds character data rather than numbers. Todd On Fri, 2

Re: '001' -> '1' in Sqlite!!

2007-02-02 Thread mamcxyz
Thanks, but I don't use the model. Is a direct insert. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com To unsubscribe from thi

Re: '001' -> '1' in Sqlite!!

2007-02-02 Thread Joseph Heck
change your model so that it's storing a CharField or TextField if you want that level of control over representation. -joe On 2/2/07, mamcxyz <[EMAIL PROTECTED]> wrote: > > > Hi, > > I found that in Sqlite when I do: > > INSERT INTO Sample (Code) VALUES ('001') > > Get converted to '1' > >