python - How to index document I want to query multiple random fields dynamodb boto? -


i have following in dynamo:

{ username: "joe", account_type: "standard", favorite_food: "veggies", favorite_sport: "hockey", favorite_person: "steve", date_created: <utc-milliseconds>, record_type: "person" } 

my table created follows:

table('persons', schema=[hashkey('record_type')], global_indexes=[globalallindex('indexone', parts=[hashkey('favorite_food')])]) 

i want able perform queries can query for:

favorite_food = "meat", favorite_sport="hockey" 

or just

favorite_food = "meat", date_created > <some date in utc-milliseconds> 

or just: favorite_food = "meat"

or

   account_type: "premium", favorite_food: "veggies" 

how many indices should creating global, secondary, etc. able perform "query" opposed scan if possible, cannot sure user query. want list of "usernames" match query.


Comments

Popular posts from this blog

Payment information shows nothing in one page checkout page magento -

tcpdump - How to check if server received packet (acknowledged) -