Skip to content

Commit 1923d5e

Browse files
author
Benni Rogge
committed
align attribute name and values
1 parent 78a7c35 commit 1923d5e

File tree

4 files changed

+6
-6
lines changed

4 files changed

+6
-6
lines changed

examples/SDK/kotlin/data_plane/WorkingWithItems/src/main/kotlin/BatchGetItem.kt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,8 +39,8 @@ suspend fun main() {
3939
val tableName = "YourTableName"
4040
val keys =
4141
listOf(
42-
mapOf("PrimaryKey" to AttributeValue.S("YourPrimaryKeyValue1")),
43-
mapOf("PrimaryKey" to AttributeValue.S("YourPrimaryKeyValue2")),
42+
mapOf("id" to AttributeValue.S("12345")),
43+
mapOf("id" to AttributeValue.S("1234")),
4444
)
4545

4646
batchGetItem(tableName, keys)

examples/SDK/kotlin/data_plane/WorkingWithItems/src/main/kotlin/DeleteItem.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ suspend fun deleteItem(
1717

1818
suspend fun main() {
1919
val tableName = "YourTableName"
20-
val key = mapOf("PrimaryKey" to AttributeValue.S("YourPrimaryKeyValue"))
20+
val key = mapOf("id" to AttributeValue.S("1234"))
2121

2222
deleteItem(tableName, key)
2323
}

examples/SDK/kotlin/data_plane/WorkingWithItems/src/main/kotlin/GetItem.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ suspend fun getItem(
2121

2222
suspend fun main() {
2323
val tableName = "YourTableName"
24-
val key = mapOf("PrimaryKey" to AttributeValue.S("YourPrimaryKeyValue"))
24+
val key = mapOf("id" to AttributeValue.S("1234"))
2525

2626
getItem(tableName, key)
2727
}

examples/SDK/kotlin/data_plane/WorkingWithItems/src/main/kotlin/TransactGetItem.kt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,8 +31,8 @@ suspend fun main() {
3131
val tableName2 = "YourTableName2"
3232
val requests =
3333
mapOf(
34-
tableName1 to mapOf("PrimaryKey1" to AttributeValue.S("YourPrimaryKeyValue1")),
35-
tableName2 to mapOf("PrimaryKey2" to AttributeValue.S("YourPrimaryKeyValue2")),
34+
tableName1 to mapOf("id" to AttributeValue.S("12345")),
35+
tableName2 to mapOf("id" to AttributeValue.S("1234")),
3636
)
3737
transactGetItem(requests)
3838
}

0 commit comments

Comments
 (0)