[ADQL] Fix recursive replacement using SimpleReplaceHandler.
Before correction, if an ADQlObject (e.g. a function or a sub-query) contains another ADQLObject and that both (i.e. parent and child) are matching in a SimpleReplaceHandler and are asked to be replaced, only the parent seemed to have been replaced. However, the child has been replaced, but in the former instance of the parent ; and so its replacement is not visible in the final query. For instance: if all mathematical functions must be replaced by a dumb UDF named 'foo' in the ADQL query: "SELECT sqrt(abs(81)) FROM myTable" ,the result should be: "SELECT foo(foo(81)) FROM myTable" ,but before this correction it was: "SELECT foo(abs(81)) FROM myTable".
Loading
Please register or sign in to comment