Mitchell Vincent wrote: > > I have an old SQLite 2.8 database that shared it's schema with > PostgreSQL. One of the nifty things about PostgreSQL (that admittedly > has me spoiled) is the ability to just say "varchar" without any > length specifier. > > Specifying "varchar" in SQLite works great - no problem at all. Until > I tried to use it with ODBC. The SQLite ODBC driver works fine but > assumes a 255 character limit. As soon as it returns a result longer > than 255 it blows an error. > > I see in the SQLite ODBC driver's documentation that it does support > > 255 varchar fields but I _assume_ have to specify that it's > 255 in > the schema. > > Now comes the fun part. I'm converting these databases (and there are > a LOT of them), I'm doing "sqlite OLD.DB .dump | sqlite3 NEW.DB" which > works flawlessly. Is there any way to change the schema on the fly to > say "Varchar(1024)" instead of just "varchar" (or just use an SQLite > 'type' of "text") ?
Mitchell, the artificial limitation of VARCHAR columns to 255 chars in the SQLite ODBC drivers is yet another tribute to M$ACCE$$. If you want a proper untruncated mapping to larger VARCHAR columns use "text" or "memo" in your CREATE TABLE statement. These will be mapped to SQL_LONGVARCHAR by the drivers. Sorry for that inconvenience, but blame billg, not me ;-) Regards, Christian ----------------------------------------------------------------------------- To unsubscribe, send email to [EMAIL PROTECTED] -----------------------------------------------------------------------------