HIVE-4547: A complex create view statement fails with new Antlr 3.4
Review Request #11084 - Created May 13, 2013 and updated
The parser has a translation map where its possible to replace all the text with the appropriate escaped version in case of a view creation. This holds all individual translations and where they apply in the view definition. The newer antlr version seems to be more restrictive and throws assertion if there's an overlaps in these escape positions. The original patch for antlr upgrade added a check to take care of some of the simpler overlap cases found by unit tests. There are few more scenarios like the one in the customer case which are not covered. The patch includes Traverse the list of translation in a loop and look for all the possible overlaps.
Ran full test suite. Added new test.