Tweak and prod at will. Just keep in mind that bitmasks are the most likely means of
implementing subtle changes in behavior between releases, and are therefore least
likely to be reverse-engineered safely. Read-only is the safest use of a bitmask, but is
still not without risk (mostly errors of omission).
There are three ways to access spatial data through ArcGIS:
+ Via ArcObjects
+ Via the ArcSDE API
+ Via SQL
ArcObjects uses ArcSDE uses SQL, so the safest way to manipulate database objects
registered with ArcGIS is AO. Simple feature classes which are only registered with
ArcSDE are safe to manipulated with ArcSDE, and databse objects which have not been
registered with ArcSDE are safe to be manipulated with SQL.
Nothing in the ArcSDE data model addresses constraints, but ALLOWS NULL/NOT NULL is
a fundamental column property. Both the ArcSDE API and the 'sdetable' command allow
alteration of the allows_null property. If the table is registered with ArcGIS I'd recommend
using ArcGIS to make the change, otherwise 'sdetable -o alter_column -x ALLOW_NULLS -t ...'
will make sure that ArcSDE sets the correct bitmask in the columns table.
Altering tables through database interfaces is a common part of spatial database
maintenance, though some alterations are riskier than others (especially with regard
to versioned tables). Since, in the end, most of ArcSDE is implemented as SQL, most
anything you break can be fixed again (just make sure you have a verified backup/
recovery procedure and a fresh snapshot before you venture into unsupported realms).
It is also important to keep causality in mind -- changing the bitmask flag which
indicates a column's 'allows_null' property does not change the target column's
null behavoir in the database. This option should only be pursued if an 'sdetable
-o describe' as the owner reflects different information than a DESCRIBE does
(and it still might not alter ArcGIS's interpretation of the same column). The few
times I've needed to hack the column registry, I usually wound up reloading the
table anyway, making it a moot exercise.
- V