DynamoDB: Obtener todos los elementos

I'm trying to retrieve all of the keys from a DynamoDB table in an optimized way. There are millions of keys.

In Cassandra I would probably create a single row with a column for every key which would eliminate to do a full table scan. DynamoDBs 64k limit per Item would seemingly preclude this option though.

Is there a quick way for me to get back all of the keys?

Gracias.

preguntado el 01 de febrero de 12 a las 22:02

1 Respuestas

I believe the DynamoDB analogue would be to use composite keys: have a primary key of "allmykeys" and a range attribute of the originals being tracked: http://docs.amazonwebservices.com/amazondynamodb/latest/developerguide/DataModel.html#DataModelPrimaryKey

I suspect this will scale poorly to billions of entries, but should work adequately for a few million.

Finally, again as with Cassandra, the most straightforward solution is to use map/reduce to get the keys: http://docs.amazonwebservices.com/amazondynamodb/latest/developerguide/EMRforDynamoDB.html

Respondido 02 Feb 12, 09:02

No es la respuesta que estás buscando? Examinar otras preguntas etiquetadas or haz tu propia pregunta.