Index for NOT NULL constraint?
Posted in 2006
Topics: General Discussion
Hello. Can anyoine explain this? It's not that it causes me any headache, I'm just curious...:-)
Davorin Kremenjas wrote: > Hello. > Can anyoine explain this? It's not that it causes me any headache, I'm just > curious...:-) > From the SQL Reference explanation of sysconstraints system table: > ------------------------------------- > An entry is also placed in the sysindexes system catalog table (or > sysindices view for Dynamic Server) for each unique, primary key, NOT NULL, > or referential constraint that does not already have a corresponding entry > in sysindexes or sysindices. > ------------------------------------- > I (think) I understand the part about building indices for unique, primary > key or referential constraint, but why NOT NULL? > I must admit I don't understand it. > Thanks everyone. That's a documentation bug. NOT NULL constraints do NOT create an index. As you surmise, none is required. Art S. Kagel