Github user cloud-fan commented on the issue:
https://github.com/apache/spark/pull/14962
```
val tableName = "tab1"
withTable(tableName) {
Seq((1, 2), (3, 4)).toDF("i", "j").createOrReplaceTempView(tableName)
sql(s"select * from $tableName where i < 2")
.write.mode(SaveMode.Overwrite).saveAsTable(tableName)
sql(s"select * from $tableName").show()
}
```
@gatorsmile , why it's an issue? In this case, we create a temp view called
`tab1` with 2 rows first. Then we create a table also called `tab1` with 1 row.
Finally in select we use the name `tab1`, which refers to the temp view, it has
2 rows.
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]