Toad World® Forums

ScriptDom parsing and NoViableAltExceptions


#1

If you have ever tried to debug a program that used the TSql Script Dom to parse some T-SQL you will know that the process is extremely slow and this is due to the volume of NoViableAltExceptions (and others) that are thrown and then caught. Because these are first chance exceptions they are being handled and it is the way that the script dom interacts with Antlr and the Lexer that they use. When you debug a program what happens is you have two processes, process one is the debuger, this starts (or attaches) to process two, the debugee.


This is a companion discussion topic for the original entry at https://blog.toadworld.com/2017/03/02/scriptdom-parsing-and-noviablealtexceptions