Skip to content

Commit 3fa65dd

Browse files
committed
variable name corrected
1 parent 45b424c commit 3fa65dd

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

articles/cosmos-db/sql/create-sql-api-spark.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -191,7 +191,7 @@ Using the same `cosmos.oltp` data source, we can do partial update in Cosmos DB
191191
#### [Python](#tab/python)
192192

193193
```python
194-
cfgSet = {"spark.cosmos.accountEndpoint": cosmosEndpoint,
194+
cfgPatch = {"spark.cosmos.accountEndpoint": cosmosEndpoint,
195195
"spark.cosmos.accountKey": cosmosMasterKey,
196196
"spark.cosmos.database": cosmosDatabaseName,
197197
"spark.cosmos.container": cosmosContainerName,
@@ -212,7 +212,7 @@ dfBeforePatch.show()
212212
data = [{"id": id, "name": "Joel Brakus"}]
213213
patchDf = spark.createDataFrame(data)
214214

215-
patchDf.write.format("cosmos.oltp").mode("Append").options(**cfgSet).save()
215+
patchDf.write.format("cosmos.oltp").mode("Append").options(**cfgPatch).save()
216216

217217
dfAfterPatch = spark.sql(query)
218218
print("document after patch operation")
@@ -225,7 +225,7 @@ For more samples related to partial document update, see the Github code sample
225225
#### [Scala](#tab/scala)
226226

227227
```scala
228-
val cfgSet = Map("spark.cosmos.accountEndpoint" -> cosmosEndpoint,
228+
val cfgPatch = Map("spark.cosmos.accountEndpoint" -> cosmosEndpoint,
229229
"spark.cosmos.accountKey" -> cosmosMasterKey,
230230
"spark.cosmos.database" -> cosmosDatabaseName,
231231
"spark.cosmos.container" -> cosmosContainerName,

0 commit comments

Comments
 (0)