Skip to content

Commit 510a483

Browse files
committed
Fixed some incorrect snippet tags. Also fixed some gerunds. Also updated the .gitignore file to ignore php unit test results.
1 parent e2982e9 commit 510a483

File tree

5 files changed

+32
-24
lines changed

5 files changed

+32
-24
lines changed

.doc_gen/metadata/dynamodb_metadata.yaml

+8-2
Original file line numberDiff line numberDiff line change
@@ -1655,8 +1655,11 @@ dynamodb_Scenario_PartiQLSingle:
16551655
excerpts:
16561656
- description:
16571657
snippet_tags:
1658-
- php.example_code.dynamodb.partiql_basics.getItem
1658+
- php.example_code.dynamodb.partiql_basics.scenario
1659+
- php.example_code.dynamodb.service.insertItemByPartiQL
16591660
- php.example_code.dynamodb.service.getItemByPartiQL
1661+
- php.example_code.dynamodb.service.updateItemByPartiQL
1662+
- php.example_code.dynamodb.service.deleteItemByPartiQL
16601663
Python:
16611664
versions:
16621665
- sdk_version: 3
@@ -1747,8 +1750,11 @@ dynamodb_Scenario_PartiQLBatch:
17471750
excerpts:
17481751
- description:
17491752
snippet_tags:
1750-
- php.example_code.dynamodb.partiql_batch.getItem
1753+
- php.example_code.dynamodb.partiql_batch.scenario
1754+
- php.example_code.dynamodb.service.insertItemByPartiQLBatch
17511755
- php.example_code.dynamodb.service.getItemByPartiQLBatch
1756+
- php.example_code.dynamodb.service.updateItemByPartiQLBatch
1757+
- php.example_code.dynamodb.service.deleteItemByPartiQLBatch
17521758
Python:
17531759
versions:
17541760
- sdk_version: 3

.gitignore

+3-1
Original file line numberDiff line numberDiff line change
@@ -13,4 +13,6 @@ venv
1313
.*~
1414
xcuserdata
1515
.swiftpm
16-
Package.resolved
16+
Package.resolved
17+
*.phpunit.cache
18+
*.phpunit.result.cache

php/example_code/dynamodb/Readme.md

+17-17
Original file line numberDiff line numberDiff line change
@@ -25,34 +25,34 @@ For more information, see
2525

2626
Code excerpts that show you how to call individual service functions.
2727

28-
* [Creating a table](dynamodb_basics/GettingStartedWithDynamoDB.php)(`create_table`)
29-
* [Deleting a table](DynamoDBService.php)(`delete_table`)
30-
* [Deleting an item from a table](dynamodb_basics/GettingStartedWithDynamoDB.php)(`delete_item`)
31-
* [Getting an item from a table](dynamodb_basics/GettingStartedWithDynamoDB.php)(`get_item`)
32-
* [Putting an item into a table](dynamodb_basics/GettingStartedWithDynamoDB.php)(`put_item`)
33-
* [Putting items loaded from a JSON file into a table](dynamodb_basics/GettingStartedWithDynamoDB.php)
28+
* [Create a table](dynamodb_basics/GettingStartedWithDynamoDB.php)(`create_table`)
29+
* [Delete a table](DynamoDBService.php)(`delete_table`)
30+
* [Delete an item from a table](dynamodb_basics/GettingStartedWithDynamoDB.php)(`delete_item`)
31+
* [Get an item from a table](dynamodb_basics/GettingStartedWithDynamoDB.php)(`get_item`)
32+
* [Put an item into a table](dynamodb_basics/GettingStartedWithDynamoDB.php)(`put_item`)
33+
* [Put items loaded from a JSON file into a table](dynamodb_basics/GettingStartedWithDynamoDB.php)
3434
(`put_item`)
35-
* [Querying items by using a key condition expression](dynamodb_basics/GettingStartedWithDynamoDB.php)
35+
* [Query items by using a key condition expression](dynamodb_basics/GettingStartedWithDynamoDB.php)
3636
(`query`)
37-
* [Scanning a table for items](dynamodb_basics/GettingStartedWithDynamoDB.php)
37+
* [Scan a table for items](dynamodb_basics/GettingStartedWithDynamoDB.php)
3838
(`scan`)
39-
* [Updating an item in a table](dynamodb_basics/GettingStartedWithDynamoDB.php)
39+
* [Update an item in a table](dynamodb_basics/GettingStartedWithDynamoDB.php)
4040
(`update_item`)
41-
* [Creating an item in a table with PartiQL](partiql_basics/GettingStartedWithPartiQL.php)
41+
* [Create an item in a table with PartiQL](partiql_basics/GettingStartedWithPartiQL.php)
4242
(`executeStatement - INSERT`)
43-
* [Getting an item in a table with PartiQL](partiql_basics/GettingStartedWithPartiQL.php)
43+
* [Get an item in a table with PartiQL](partiql_basics/GettingStartedWithPartiQL.php)
4444
(`executeStatement - SELECT`)
45-
* [Updating an item in a table with PartiQL](partiql_basics/GettingStartedWithPartiQL.php)
45+
* [Update an item in a table with PartiQL](partiql_basics/GettingStartedWithPartiQL.php)
4646
(`executeStatement - UPDATE`)
47-
* [Deleting an item in a table with PartiQL](partiql_basics/GettingStartedWithPartiQL.php)
47+
* [Delete an item in a table with PartiQL](partiql_basics/GettingStartedWithPartiQL.php)
4848
(`executeStatement - DELETE`)
49-
* [Creating an item in a table with PartiQL - BatchExecuteStatement](partiql_basics/GettingStartedWithPartiQLBatch.php)
49+
* [Create an item in a table with PartiQL - BatchExecuteStatement](partiql_basics/GettingStartedWithPartiQLBatch.php)
5050
(`executeStatement - INSERT`)
51-
* [Getting an item in a table with PartiQL - BatchExecuteStatement](partiql_basics/GettingStartedWithPartiQLBatch.php)
51+
* [Get an item in a table with PartiQL - BatchExecuteStatement](partiql_basics/GettingStartedWithPartiQLBatch.php)
5252
(`executeStatement - SELECT`)
53-
* [Updating an item in a table with PartiQL - BatchExecuteStatement](partiql_basics/GettingStartedWithPartiQLBatch.php)
53+
* [Update an item in a table with PartiQL - BatchExecuteStatement](partiql_basics/GettingStartedWithPartiQLBatch.php)
5454
(`executeStatement - UPDATE`)
55-
* [Deleting an item in a table with PartiQL - BatchExecuteStatement](partiql_basics/GettingStartedWithPartiQLBatch.php)
55+
* [Delete an item in a table with PartiQL - BatchExecuteStatement](partiql_basics/GettingStartedWithPartiQLBatch.php)
5656
(`executeStatement - DELETE`)
5757

5858
### Scenario examples

php/example_code/dynamodb/partiql_basics/GettingStartedWithPartiQL.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,7 @@ public function run()
102102

103103
list($statement, $parameters) = $service->buildStatementAndParameters("UPDATE", $tableName, $key, $attributes);
104104
$service->updateItemByPartiQL($statement, $parameters);
105-
echo "Movie added and updated.";
105+
echo "Movie added and updated.\n";
106106

107107

108108

@@ -132,7 +132,7 @@ public function run()
132132
echo "Okay, you have rated {$movie['Items'][0]['title']['S']} as a {$movie['Items'][0]['rating']['N']}\n";
133133

134134
# snippet-start:[php.example_code.dynamodb.partiql_basics.deleteItem]
135-
$service->deleteItemByKey($tableName, $key);
135+
$service->deleteItemByPartiQL($statement, $parameters);
136136
echo "But, bad news, this was a trap. That movie has now been deleted because of your rating...harsh.\n";
137137
# snippet-end:[php.example_code.dynamodb.partiql_basics.deleteItem]
138138

php/example_code/dynamodb/partiql_basics/GettingStartedWithPartiQLBatch.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,7 @@ public function run()
102102

103103
list($statement, $parameters) = $service->buildStatementAndParameters("UPDATE", $tableName, $key, $attributes);
104104
$service->updateItemByPartiQLBatch($statement, $parameters);
105-
echo "Movie added and updated.";
105+
echo "Movie added and updated.\n";
106106

107107
$batch = json_decode(loadMovieData());
108108

@@ -132,7 +132,7 @@ public function run()
132132
as a {$movie['Responses'][0]['Item']['rating']['N']}\n";
133133

134134
# snippet-start:[php.example_code.dynamodb.partiql_batch.deleteItem]
135-
$service->deleteItemByKey($tableName, $key);
135+
$service->deleteItemByPartiQLBatch($statement, $parameters);
136136
echo "But, bad news, this was a trap. That movie has now been deleted because of your rating...harsh.\n";
137137
# snippet-end:[php.example_code.dynamodb.partiql_batch.deleteItem]
138138

0 commit comments

Comments
 (0)