Closed StanleySathler closed 1 year ago
Hey, @StanleySathler. Thanks for the kind words!
The current model API is designed to always have a single primary key. Marking multiple properties with primaryKey()
will throw, and that is expected.
Note that you don't have to mark a property as a primary key to query by it. Primary keys are necessary for internal model lookup optimization and to guard against creating multiple entities with the same primary key.
If you wish to query by timelineItemId
you can do that at any time:
db. timelineItemEffectMetadata.findFirst({
where: {
timelineItemId: { equals: 'abc-123' }
}
})
Please let me know if I understood your intention wrong here.
Thanks for the hard work - the tool is awesome 👏
One of my entities has two fields to compose a multi-field ID, but I can't use:
Any way to work around this?