1. [SPARK-37501][SQL] CREATE/REPLACE TABLE should qualify location for v2 (details)
Commit 38115cb907ec93151382260cda327330e78ca340 by wenchen
[SPARK-37501][SQL] CREATE/REPLACE TABLE should qualify location for v2 command

### What changes were proposed in this pull request?
1. Rename method name `makeQualifiedNamespacePath` -> `makeQualifiedLocationPath` in `CatalogUtils`, so it not only for db/namespace, also for table.
2. Override the method `makeQualifiedLocationPath` to take more types of parameters
3. In `CreateTableExec` add handle the `location` properties convert.
4. Add handle for `Replace table` command.

### Why are the changes needed?
keep consistent for v1 and v2, and disscuss at [#comments](

### Does this PR introduce _any_ user-facing change?

### How was this patch tested?
existed test case.

Closes #34758 from Peng-Lei/qualify-location.

Authored-by: PengLei <>
Signed-off-by: Wenchen Fan <>
The file was modifiedsql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/catalog/ExternalCatalogUtils.scala (diff)
The file was modifiedsql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/catalog/SessionCatalog.scala (diff)
The file was modifiedsql/core/src/main/scala/org/apache/spark/sql/execution/datasources/v2/DataSourceV2Strategy.scala (diff)
The file was modifiedsql/core/src/test/scala/org/apache/spark/sql/connector/DataSourceV2SQLSuite.scala (diff)