DanielLeens commented on issue #13361:
URL: https://github.com/apache/seatunnel/issues/13361#issuecomment-7078978088

   Classification: A / Transform-V2 Calcite timestamp runtime representation.
   
   Thank you for checking the physical representation as well as the declared 
type precision. Current `dev` at `86bef7694d68fb8c167b79626a30a4236d18208f` 
still converts `LocalDateTime` to `java.sql.Timestamp` at 
`CalciteValueConverter.toCalcite()`, while its numeric timestamp path 
reconstructs from epoch milliseconds. Your Calcite 1.38.0 experiment adds the 
decisive point: raising declared precision to six does not change Enumerable's 
`long`/`Long` runtime value, so `.123456` and `.123789` still collapse to the 
same millisecond.
   
   This rules out both an epoch-millisecond adapter change and a 
type-precision-only change. Either would replace the visible 
`ClassCastException` with silently incorrect projection, comparison, and 
interval behavior. I agree that no SeaTunnel adapter PR should be opened on 
either basis.
   
   Please keep this Issue open as a blocked runtime-representation problem and 
track the upstream Calcite capability needed to carry sub-millisecond values 
through Enumerable projection, comparison, and arithmetic. A future SeaTunnel 
proposal must first show a precision-preserving physical representation on the 
bundled Calcite version, then cover `TIMESTAMP` and `TIMESTAMP_TZ`, standalone 
projection, whole-second arithmetic, equality/inequality/ordering, null 
controls, and two distinct values in the same millisecond. The existing 
SeaTunnel timestamp types and connector APIs remain out of scope for any such 
fix.
   


-- 
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]

Reply via email to