Finish clean up generateOutputSchema and resolveColumnIndexes. Need to profile now.