We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b8b67ae commit c3b59c6Copy full SHA for c3b59c6
sql/core/src/main/scala/org/apache/spark/sql/execution/LocalTableScanExec.scala
@@ -37,7 +37,7 @@ case class LocalTableScanExec(
37
"numOutputRows" -> SQLMetrics.createMetric(sparkContext, "number of output rows"))
38
39
@transient private lazy val unsafeRows: Array[InternalRow] = {
40
- if (rows.isEmpty) {
+ if (rows == null || rows.isEmpty) {
41
Array.empty
42
} else {
43
val proj = UnsafeProjection.create(output, output)
@@ -59,7 +59,9 @@ case class LocalTableScanExec(
59
}
60
61
override protected def stringArgs: Iterator[Any] = {
62
+ if (rows == null) {
63
+ Iterator("<unknown>", output)
64
+ } else if (rows.isEmpty) {
65
Iterator("<empty>", output)
66
67
Iterator(output)
0 commit comments