git-hulk commented on code in PR #1574:
URL:
https://github.com/apache/datafusion-sqlparser-rs/pull/1574#discussion_r1864879741
##########
src/ast/data_type.rs:
##########
@@ -25,10 +25,21 @@ use serde::{Deserialize, Serialize};
#[cfg(feature = "visitor")]
use sqlparser_derive::{Visit, VisitMut};
-use crate::ast::{display_comma_separated, ObjectName, StructField, UnionField};
+use crate::ast::{display_comma_separated, ObjectName, StructField, UnionField,
Value};
use super::{value::escape_single_quote_string, ColumnDef};
+#[derive(Debug, Clone, PartialEq, PartialOrd, Eq, Ord, Hash)]
+#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
+#[cfg_attr(feature = "visitor", derive(Visit, VisitMut))]
+pub enum EnumValue {
+ String(String),
+ /// ClickHouse allows to specify an integer value for each enum value.
+ ///
+ ///
[clickhouse](https://clickhouse.com/docs/en/sql-reference/data-types/enum)
+ Pair(String, Value),
+}
Review Comment:
Yes, That's a good suggestion.
--
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]