
IF (SELECT length
  FROM SysObjects WITH (NOLOCK) 
    INNER JOIN SysColumns WITH (NOLOCK) ON SysColumns.Id = SysObjects.ID 
    AND SysColumns.Name = 'UserID'
    WHERE SysObjects.Name = 'RESERVATIONS') < 20

	alter table reservations
		alter column USERID varchar(20) null