[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Can I add "NOT NULL" to PRISTINE table columns?

From: Julian Foad <julian.foad_at_wandisco.com>
Date: Tue, 30 Nov 2010 15:34:21 +0000

In r1040574 I noted that the 'size' and 'md5_checksum' columns in the
PRISTINE table are never currently null. The latter is required by
current code to be non-null.

I feel it would be better to have the schema specify 'NOT NULL' for
these two columns. Just a feeling of Goodness, no concrete reasons.

I imagine it should be possible to add 'NOT NULL' to these columns
without performing a format bump or writing any upgrade code. Am I
right?

 CREATE TABLE PRISTINE (
[...]
      NULL if unknown, and (thus) the pristine copy is incomplete/unusable.
+ ### We always set this; there may be no need to allow NULL. Shall we
+ add "NOT NULL" to the schema? */
   size INTEGER,
 
[...]
+ ### We always set this and require it to be non-null. Can we add
+ "NOT NULL" to the schema? */
   md5_checksum TEXT
   );

- Julian
Received on 2010-11-30 16:35:04 CET

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.