mvzink commented on code in PR #1739: URL: https://github.com/apache/datafusion-sqlparser-rs/pull/1739#discussion_r1970437405
########## src/ast/data_type.rs: ########## @@ -238,6 +238,26 @@ pub enum DataType { UnsignedBigInt(Option<u64>), /// Unsigned Int8 with optional display width e.g. INT8 UNSIGNED or INT8(11) UNSIGNED UnsignedInt8(Option<u64>), + /// Signed integer as used in [MySQL CAST] target types, with optional `INTEGER` suffix: + /// `SIGNED [INTEGER]` + /// + /// Note that this doesn't accept a display width and is reversed from the syntax used in column + /// definitions ([`DataType::Int`]): `INTEGER [SIGNED]` + /// + /// Semantically equivalent to `BIGINT`. + /// + /// [MySQL CAST]: https://dev.mysql.com/doc/refman/8.4/en/cast-functions.html + Signed(bool), Review Comment: I'm not sure exactly what you mean. Different variants `Signed = SIGNED` and `SignedInteger = SIGNED INTEGER`? The only reason I didn't do that is there's already `UnsignedInt = INT[EGER] UNSIGNED` and it would be even more confusing to have `UnsignedInteger = UNSIGNED INTEGER`, and very disruptive to change the existing `UnsignedInt` to `IntUnsigned` or something. -- 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: github-unsubscr...@datafusion.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: github-unsubscr...@datafusion.apache.org For additional commands, e-mail: github-h...@datafusion.apache.org