SQLite Forum

sqlite3 rounding off the values of timestamp causing issues
Login
Thanks for the response, Gunter!

I understand the confusion. The issue is not with adding the values as real values instead of strings. I can clear that by showing you this.

Using sqlite2, created a new database,
sqlite> create table xyz(id INTEGER, value TEXT);
sqlite> insert into xyz values(1, "1234");
sqlite> insert into xyz values(2, "12323453243.234234324");

# # sqlite repo_v2 .dump
BEGIN TRANSACTION;
create table xyz(id INTEGER, value TEXT);
INSERT INTO xyz VALUES(1,1234);
INSERT INTO xyz VALUES(2,12323453243.234234324);
COMMIT;

You see the quotes are gone for the numbers even though I inserted it as a string.

And sqlite3 might not be at fault as it perceives it as a real number due to the absence of quotes around the values but sqlite2 shouldn't be dumping it without the quotes.