yashmayya opened a new pull request, #16606: URL: https://github.com/apache/pinot/pull/16606
- https://github.com/apache/pinot/pull/16421 was a bug fix but unintentionally broke some multi-stage engine queries (that themselves were unintentionally supported). - Consider a query like `SELECT * FROM mytable WHERE tsCol >= '2025-08-07 00:00:00.000000'` but `tsCol` is actually a `LONG` type in the schema and not a `TIMESTAMP` type. This query actually doesn't work with the single-stage engine but worked with the MSE before the above patch. The reason is that before the above bugfix, the cast was evaluated through the [transform function variant](https://github.com/apache/pinot/blob/d9e731782afc62149b487c27e80de4d809673853/pinot-core/src/main/java/org/apache/pinot/core/operator/transform/function/CastTransformFunction.java#L180) of `CAST`, which handled timestamp strings to longs appropriately (see [here](https://github.com/apache/pinot/blob/d9e731782afc62149b487c27e80de4d809673853/pinot-core/src/main/java/org/apache/pinot/core/operator/transform/function/LiteralTransformFunction.java#L72), [here](https://github.com/apache/pinot/blob/d9e731782afc62149b487c27e80de4d809673853/pinot-common/src/main/java/org/apache/pinot/common/request/context/ LiteralContext.java#L226-L235)). - The [scalar function variant](https://github.com/apache/pinot/blob/d9e731782afc62149b487c27e80de4d809673853/pinot-common/src/main/java/org/apache/pinot/common/function/scalar/DataTypeConversionFunctions.java#L71-L77) of `CAST` though doesn't support this pattern and the above bugfix to evaluate `CAST` at compile time rather than query execution time unintentionally broke some queries. - This patch fixes the scalar function variant of `CAST` to also support the timestamp string to long conversion. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
