Skip to content

Commit

Permalink
address review comments
Browse files Browse the repository at this point in the history
  • Loading branch information
kazuyukitanimura committed Jun 11, 2024
1 parent 8ce4344 commit f028425
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 13 deletions.
2 changes: 0 additions & 2 deletions .github/workflows/spark_sql_test_ansi.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,12 +24,10 @@ concurrency:
on:
push:
paths-ignore:
- "doc/**"
- "docs/**"
- "**.md"
pull_request:
paths-ignore:
- "doc/**"
- "docs/**"
- "**.md"
# manual trigger
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -170,7 +170,7 @@ && isUnsignedIntTypeMatched(logicalTypeAnnotation, 64)) {
break;
case INT96:
if (sparkType == TimestampNTZType$.MODULE$) {
if (isSpark40Plus()) return;
if (isSpark40Plus()) return; // Spark 4.0+ supports Timestamp NTZ with INT96
convertErrorForTimestampNTZ(typeName.name());
} else if (sparkType == DataTypes.TimestampType) {
return;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,11 +33,8 @@ trait CometExprShim {
(unhex.child, Literal(false))
}

protected def isTimestampNTZType(dt: DataType): Boolean = dt match {
// `TimestampNTZType` is private
case dt if dt.typeName == "timestamp_ntz" => true
case _ => false
}
protected def isTimestampNTZType(dt: DataType): Boolean =
dt.typeName == "timestamp_ntz" => true // `TimestampNTZType` is private

protected def evalMode(c: Cast): CometEvalMode.Value = CometEvalMode.fromBoolean(c.ansiEnabled)
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,11 +33,8 @@ trait CometExprShim {
(unhex.child, Literal(false))
}

protected def isTimestampNTZType(dt: DataType): Boolean = dt match {
// `TimestampNTZType` is private
case dt if dt.typeName == "timestamp_ntz" => true
case _ => false
}
protected def isTimestampNTZType(dt: DataType): Boolean =
dt.typeName == "timestamp_ntz" => true // `TimestampNTZType` is private

protected def evalMode(c: Cast): CometEvalMode.Value = CometEvalMode.fromBoolean(c.ansiEnabled)
}

0 comments on commit f028425

Please sign in to comment.