1 回答
- 最新
- 投票最多
- 评论最多
0
【以下的回答经过翻译处理】 属性值是映射类型。
尝试
{
const tableName = 'BattleRoyalePlayerLobbyTable';
const indexName = 'lobbyId-index';
const keyConditionExpression = '# lobbyId = : lobbyid';
const expressionAttributeNames = {'#lobyId':'lobbyId'};
const expressionAttributeValues = { ': lobbyid':message.lobbyId};
const exclusiveStartKey = {};
let queryResult = GameSparks()。DynamoDB()。QueryIndex(
tableName,
indexName,
keyConditionExpression,
expressionAttributeNames,
expressionAttributeValues,
exclusiveStartKey);
return GameSparks().Messaging().Response({ 'players': queryResult.Items });
}
catch(ex)
{
return GameSparks().Messaging().Response({ "players": [], "error": ex.message });
}