Fix STI support so that the base class uses NULL as the value of the type column, not the actual name of the base class.