Skip to content
Closed
Changes from 1 commit
Commits
Show all changes
32 commits
Select commit Hold shift + click to select a range
0b293db
[SPARK-29774][SQL] Date and Timestamp type +/- null should be null as…
yaooqinn Nov 6, 2019
f726297
Merge branch 'master' into SPARK-29774
yaooqinn Nov 27, 2019
e7225a3
regen golden file
yaooqinn Nov 27, 2019
b925517
null - dates
yaooqinn Nov 27, 2019
cd49411
Merge branch 'master' into SPARK-29774
yaooqinn Dec 2, 2019
57b13e9
support +/-
yaooqinn Dec 2, 2019
eab6a83
support ×/÷
yaooqinn Dec 2, 2019
e8b75ba
import
yaooqinn Dec 2, 2019
02b3738
childResolved required
yaooqinn Dec 2, 2019
e89d806
regen golden file
yaooqinn Dec 2, 2019
0694e07
update comments
yaooqinn Dec 2, 2019
0f5618b
fix tests
yaooqinn Dec 3, 2019
efab3ec
fix tests
yaooqinn Dec 3, 2019
1c27be1
refine case match pattern
yaooqinn Dec 3, 2019
5df6980
fix ut
yaooqinn Dec 3, 2019
9817d2d
hack assert Equal
yaooqinn Dec 3, 2019
9808b9c
regen g f
yaooqinn Dec 3, 2019
b190612
AnalysisTest
yaooqinn Dec 3, 2019
e544137
regen g f
yaooqinn Dec 3, 2019
83705fd
fix test
yaooqinn Dec 4, 2019
846802d
date add/sub only work for int/smallint/tinyint
yaooqinn Dec 4, 2019
4af7edb
regen g f
yaooqinn Dec 4, 2019
a67be30
refine
yaooqinn Dec 4, 2019
9a1affd
type coercion for subtract timestamp
yaooqinn Dec 4, 2019
ae70022
add and reorgnize tests in datetime.sql
yaooqinn Dec 4, 2019
571225b
DateExpressionsSuite
yaooqinn Dec 4, 2019
6052e5a
fix py
yaooqinn Dec 4, 2019
928fd86
fix py
yaooqinn Dec 4, 2019
254d2d2
Revert "fix py"
yaooqinn Dec 5, 2019
5dd632c
fix py
yaooqinn Dec 5, 2019
c84d46e
rm unresolved binary arithmetic
yaooqinn Dec 5, 2019
a44948e
import
yaooqinn Dec 5, 2019
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
fix py
  • Loading branch information
yaooqinn committed Dec 4, 2019
commit 6052e5a45185c08c0847b528202afe0bca14adb4
Original file line number Diff line number Diff line change
Expand Up @@ -546,17 +546,27 @@ case class UnresolvedOrdinal(ordinal: Int)
}

trait UnresolvedBinaryExpression extends BinaryExpression with Unevaluable {
val operator: String
override lazy val resolved: Boolean = false
override def dataType: DataType = throw new UnresolvedException(this, "dataType")
override def sql: String = s"${left.sql} $operator ${right.sql}"
}

case class UnresolvedAdd(left: Expression, right: Expression) extends UnresolvedBinaryExpression
case class UnresolvedAdd(left: Expression, right: Expression) extends UnresolvedBinaryExpression {
override val operator: String = "+"
}

case class UnresolvedSubtract(left: Expression, right: Expression)
extends UnresolvedBinaryExpression
extends UnresolvedBinaryExpression {
override val operator: String = "-"
}

case class UnresolvedMultiply(left: Expression, right: Expression)
extends UnresolvedBinaryExpression
extends UnresolvedBinaryExpression {
override val operator: String = "*"
}

case class UnresolvedDivide(left: Expression, right: Expression)
extends UnresolvedBinaryExpression
extends UnresolvedBinaryExpression {
override val operator: String = "/"
}