2017-08-04 52 views
0

我正嘗試從AWS CLI使用AWS SimpleDB的select命令。AWS SimpleDB CLI:如何使用'select'命令?

所需的呼叫如下: select --select-expression <value>

select-expression被描述如下:--select-expression (string) The expression used to query the domain.

The select is supposed to be similar to the SQL select statement,但我一直對語法收到錯誤,如:

aws sdb select --select-expression "select * from my-domain"

An error occurred (InvalidQueryExpression) when calling the Select operation: The specified query expression syntax is not valid.

我無法找到任何有關正確語法的文檔或示例。

+1

附註:Amazon SimpleDB已被棄用。它仍然存在,它仍然在運行,[如果你知道在哪裏可以找到文檔](http://docs.aws.amazon.com/AmazonSimpleDB/latest/DeveloperGuide/Welcome.html)。但是,如果您正在尋找長期解決方案,請考慮使用Amazon DynamoDB。 –

回答

1

我找到了解決辦法 - 原來我需要使用單引號的查詢和特殊字符周圍的表名:

AWS SDB選擇 - 選擇表達「SELECT * FROM`我的域`'