Use this tag when your post is about Amazon DynamoDB data modeling.
Questions tagged [amazon-dynamodb-data-modeling]
30 questions
0
votes
1 answer
DynamoDB Model Chronological Shipment Update Data
I recently just started learning about DynamoDB single table design. Now, I am trying to model Shipment Update data that has the following properties:
an account has multiple users
an account has multiple shipments
a shipment can change eta…

billydh
- 975
- 11
- 27
0
votes
0 answers
Object models for DyanamoDbTable
I’m entirely new to DynamoDB
After researching I concluded to use ONE table for app design.
So I have a DynamoDB Table as PK, SK, CONTENT, < MANY OTHER ATTRIBUTES>.
My model in java looks something like below
@DynamoDBTable(tableName =…

ThrowableException
- 1,168
- 1
- 8
- 29
0
votes
2 answers
Modelling Complex Types for DynamoDB in Kotlin
I have a DynamoDB table that I need to read/write to. I am trying to create a model for reading and writing from DynamoDB with Kotlin. But I keep encountering com.amazonaws.services.dynamodbv2.datamodeling.DynamoDBMappingException: MyModelDB[myMap];…

Ryan T.
- 197
- 1
- 15
0
votes
1 answer
DynamoDB Table Design: How do I model a one to many relationship where I need all of the "one" items and one of "many" sorted by some attribute
I've spent my entire career working with denormalized relational databases. I am having a hard time un-learning all of that in order to implement a single-table design that can handle a couple specific access patterns on an "App Store"-like personal…

iamthegeek
- 3
- 1
- 1
0
votes
1 answer
Date range query in DynamoDB local
I am using DynamoDB local to test the service. I need to find all medicalRecordIds of last 12 months from given date. I am trying to use query using DynamoDB mapper.
Following is the model class:
public @Data class MedicalRecord {
…

Sagar Kansara
- 65
- 7
0
votes
1 answer
Create index on nested array value with dynamodb
I have the following data stored in a DynamoDB table called elo-history.
{
"gameId": "chess",
"guildId": "abc123",
"id": "c3c640e2d8b76b034605d8835a03bef8",
"recordedAt": 1621095861673,
"results": [
{
"oldEloRating": null,
…

sissonb
- 3,730
- 4
- 27
- 54
0
votes
0 answers
DynamoDB Mapper For Conditional Saves With More Than One Conditions
I have been trying to use DynamoDB mapper for creating save expressions. I want to save a record iff
A particular attribute value doesn't exist.
OR
That attribute value should be greater than a particular value.
So I have created an expression for…

neethu narayanan
- 1
- 1
0
votes
1 answer
DynamoDB ItemCollection to java object
I want to convert ItemCollection into my java pojo object .I want currently doing so by following way .What is the best way to do so?
QuerySpec spec = new QuerySpec()
.withKeyConditionExpression("txn_id = :txnId")
…

avinash kumar
- 475
- 6
- 10
0
votes
1 answer
How to model a Manufacturer in DynamoDB
I come from relational database background and I'm struggling with the concepts of a single table to represents all my data in DynamoDB.
My application has Manufacturers and they give access to their staff to my portal CRM (Manufacturer Users). The…

MarkK
- 968
- 2
- 14
- 30
0
votes
1 answer
How to create dynamo db item without specifying gsi key
I am working with a dynamo db table that uses a gsi so I can query via an additional attribute, if it is present. This attribute will be updated in a process so all of the items do not have this attribute in the beginning of the process. This…

Eve Edomenko
- 421
- 1
- 3
- 13
0
votes
1 answer
Sorting items from DynamoDB using dynamic value?
I have thousands of items in a table. Each item has a numeric attribute score. What I want to do:
Given some targetScore, select all items where targetScore - n <= score <= targetScore + n (I got this part working).
Return only the first j elements…

rodrigo-silveira
- 12,607
- 11
- 69
- 123
0
votes
1 answer
DynamoDB single query to retrieve both public and private chat messages
Need some suggestions in choosing DynamoDB partition key and sort key to retrieve all public and private messages in a chat.
In the same chat room, users can send public messages and also private messages to specific people.
DynamoDB model:
For…

Abie
- 81
- 5
0
votes
1 answer
DynamoDB filtering: scan with filter expression for single entry in List type
I am trying to build a filter expression for my DynamoDB table to use in a scan in a javascript lambda function. My table schema has a field called dateRange that has the following structure (this is just an example, there could be any number of…

JMLdev
- 846
- 2
- 10
- 21
0
votes
2 answers
DynamoDB Schema - Modeling Locations inside a building
New to DynamoDB over here. I need to figure out a DynamoDB schema for different locations inside a building. Additionally, I need to be able to identify computers assigned to each of the locations. The locations are nested inside other locations.…

Rookie
- 859
- 8
- 22
0
votes
2 answers
DynamoDB How to query a non-key attribute with strong consistency?
I have the following table in DynamoDB:
Table: Person
Attributes: person_id, firstName, lastName, age, birthday
Partition Key: person_id
My problem is: I need to query all the people that are between a certain age, for instance age > 18 AND age <…

tsukanomon
- 1,220
- 1
- 19
- 23