On Tue, 4 May 2010 14:22:25 +0100, "Mark Coles" <m.co...@virgin.net> wrote:
>Hi there, > > trying to INSERT a new row into a table and got a few > errors which I think I've sorted, I was getting a > couple of errors that date columns for FirstCreated > and LastModified (datetime Type) may not be NULL, > so I included them in my insert line as follows > > INSERT INTO Aircraft (FirstCreated,LastModified,ModeS) > values ('2010-05-04 09:21:31','2010-05-04 09:21:31','C40000'); Datetime is not a type in SQLite, you are storing date/time stamps as TEXT here. > and it seems to have worked as that row is now > in my (test)database, what I was wondering about > were the boolean fields, they are all filled in > with zeroes, so this is a good sign, yes? Boolean is not a type in SQLite. You are encoding them as integer, deliberately or by accident. We have no way to know whether zero is a proper value. > Also, what about the relationships between this table > and others in the database, should everything be OK > as I want to share this but not screw up other peoples databases We cannot answer that question without knowing 1- the schema of your database 2- the schema of other peoples database 3- a type-and-data dump of your database 4- a type-and-data dump of other peoples databases You can generate 3 and 4 yourself with something like SELECT typeof(col1 AS t_col1), col1, typeof(col1 AS t_col2), col2, ... FROM atable. I think it is your job to do that comparison, not ours. If you find anything irregular you can't understand after consulting http://www.sqlite.org/datatype3.html and http://www.sqlite.org/lang_datefunc.html you can ask that specific question here. -- ( Kees Nuyt ) c[_] _______________________________________________ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users