In the previous section, the value Blue was deleted from the Color attribute of Item_03.
The following sample code snippets demonstrate displaying all attributes of Item_03.
To run the sample
Open a clean copy of GetAttributesSample.java.
Remove any comment marks from the invokeGetAttributes(service, request); line and add the following lines
after // @TODO: set request parameters here:
GetAttributes request = new GetAttributes(); String domainName = "MyStore"; String itemName = "Item_03"; request.setDomainName(domainName); request.setItemName(itemName);
Compile and run the sample. Amazon SimpleDB gets all attributes of Item_03.
To run the sample
Open AmazonSimpleDBSamples.cs.
Comment out the code you added in the previous section.
Replace the Get Attributes Action section with the following:
GetAttributes getAttributesAction = new GetAttributes().WithDomainName("MyStore").WithItemName("Item_03");
GetAttributesSample.InvokeGetAttributes(service, getAttributesAction);
Run the sample.
Amazon SimpleDB gets all attributes of Item_03.
To run the sample
Open a clean copy of GetAttributesSample.pl.
Remove any comment marks from the invokeGetAttributes($service, $request); line and add the following lines
after the // @TODO: set request line:
my $request = Amazon::SimpleDB::Model::GetAttributes->new({
ItemName => "Item_03",
DomainName=> "MyStore"
});
Run the sample.
Amazon SimpleDB gets all attributes of Item_03.
To run the sample
Open a clean copy of GetAttributesSample.php.
Remove any comment marks from the invokeGetAttributes($service, $request); line and add the following lines
after the // @TODO: set request line:
$request = new Amazon_SimpleDB_Model_GetAttributes();
$request->setDomainName('MyStore');
$request->setItemName('Item_03');
Run the sample.
Amazon SimpleDB gets all attributes of Item_03.
To run the sample
Open AmazonSimpleDBSamples.vb.
Comment out the code you added in the previous section.
Replace the Get Attributes Action section with the following:
Dim getAttributesAction As New GetAttributes()
getAttributesAction.WithDomainName("MyStore").WithItemName("Item_03")
GetAttributesSample.InvokeGetAttributes(service, getAttributesAction)
Run the sample.
Amazon SimpleDB gets all attributes of Item_03.
To run the sample
Open the scratchpad application with a web browser.
Select GetAttributes from the Explore API list box.
Enter MyStore in the Domain Name field.
Enter Item_03 in the Item Name field.
Select from the following:
To invoke the request, click Invoke Request.
Amazon SimpleDB gets all attributes of Item_03.
To view the signed URL, click Display Signed URL. Then, copy and paste the signed URL into a browser.
Amazon SimpleDB gets all attributes of Item_03.
To view the string to sign, click Display String to Sign.