Is there a prefered way to specify a text column in SQLite?
Posted
by
JannieT
on Stack Overflow
See other posts from Stack Overflow
or by JannieT
Published on 2010-12-20T16:50:46Z
Indexed on
2010/12/21
9:54 UTC
Read the original article
Hit count: 206
Since the SQLite engine will not truncate the data you store in a text column, is there any advantage in being specific with column sizes when you define your schema? Would anyone prefer this:
CREATE TABLE contact(
id INTEGER PRIMARY KEY,
name VARCHAR(45),
title VARCHAR(10)
);
over this:
CREATE TABLE contact(
id INTEGER PRIMARY KEY,
name TEXT,
title TEXT
);
Why?
Are there advantages to not being specific?
© Stack Overflow or respective owner