-
Notifications
You must be signed in to change notification settings - Fork 59
feat: Implement Type Casting and toString for Literals #206
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
b599a7a
to
9dfc38a
Compare
3f912eb
to
59e57fc
Compare
cf43748
to
406a3f2
Compare
406a3f2
to
9525400
Compare
a62ac22
to
1e106ed
Compare
2beaf96
to
632ec79
Compare
case TypeId::kTimestamp: | ||
case TypeId::kTimestampTz: { | ||
throw IcebergError("Not implemented: ToString for " + type_->ToString()); | ||
return std::to_string(std::get<int64_t>(value_)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think these switch cases can be easily rewritten by return std::to_string(std::get<typename LiteralTraits<type_id>::ValueType>(value_));
once #185 is merged.
a194923
to
0abbf84
Compare
56088c8
to
b10b3d9
Compare
@Fokko I have resolved the conflicts and now ready for merge. Thanks! |
@HeartLinked It looks like more conflicts surfaced 😢 |
b10b3d9
to
183c18b
Compare
This is due to the merge of #253 . I've fixed the conflicts again. |
Thanks @HeartLinked ! |
iceberg::Literal
in theLiteralCaster
class to align with the Java reference implementation. This is critical for expression evaluation and predicate pushdown.ToString()
to match Java's output format for better consistency (e.g.,X'...'
for binary).ToString()
formatting.