On Wed, May 27, 2009 at 05:04:04PM +0200, H.Merijn Brand wrote: > > The ODBC 3.0 spec says > > http://web.archive.org/web/20070513203826/http://msdn.microsoft.com/library/en-us/odbc/htm/odbcsqlcolumns.asp > > > > The default value of the column. The value in this column should be > > interpreted as a string *if it is enclosed in quotation marks*. > > > > If NULL was specified as the default value, then this column is the word > > NULL, not enclosed in quotation marks. If the default value cannot be > > represented without truncation, then this column contains TRUNCATED, > > with no enclosing single quotation marks. If no default value was > > specified, then this column is NULL. > > > > *The value of COLUMN_DEF can be used in generating a new column > > definition*, except when it contains the value TRUNCATED. > > > > (The *emphasis* is mine.) > > > > So, people, what does your database driver do for these cases? > > Are COLUMN_DEF values for literal defaults returned by column_info() > > enclosed in quotation marks? > > Unify, and thus DBD::Unify, does not have support for default values > in CREATE TABLE statements at all, so just tell me what to do. Ignore > or fill with NULL
I think "If no default value was specified, then this column is NULL" fits the bill. Tim.
