Github user eychih commented on the issue:

    https://github.com/apache/carbondata/pull/2335
  
    In addition, for consistency, please use the following way to remove 
PreAggFunction:
    
        val planToRegister = 
sparkSession.sql(updatedQuery).queryExecution.analyzed.
          transform {
            case p @ logical.Project(head :: tail, _) if 
head.isInstanceOf[Alias] && head.name.equals("preAgg") => p.copy(projectList = 
tail)
            case a @ logical.Aggregate(_, head :: tail, _) if 
head.isInstanceOf[Alias] && head.name.equals("preAgg") => 
a.copy(aggregateExpressions = tail)
          }


---

Reply via email to