DERBY-6006: NullPointerException in INSERT INTO ... SELECT FROM ... ORDER BY backporting change #1417991 by kahatlen from 10.10 to 10.9 branch. A NormalizeResultSet should not expose generated ORDER BY columns to its parent.