If a column is null, does that affect the space used by the column? Is the space used fixed by the column definition? Does this vary from database to database. (I am mainly
In Oracle, it depends on type of the column and its position in the row.
If the NULL columns are last in the row, then they don't take any space at all. Oracle prepends the total row size to each row, everything that doesn't fit is considered NULL.
If there is some non-NULL data after a NULL column, then the NULL is stored as a single byte of 0xFF (that is, NULL type).
Empty VARCHAR2 is equivalent to NULL. If you test the type of a literal NULL returned from SELECT list, it will give you a VARCHAR2(0).