Hi,
I have noticed that the object ID is stored as a string in MongoDB. Is there a way to store it as ObjectID? It would be easier if the type is ObjectID for easier lookups.
I am referring to the tutorial here:
Anyone?
Hey @Rarcif — we store object IDs as strings intentionally, and there is no real easy way to store them as full ObjectIDs. This is for a few reasons, but we could certainly evaluate a way to be able to "opt in" to ObjectIDs instead of string representations in a new feature
there are a few places in the code that would need to be adjusted, but technically, this could be doable with a PR
right now, it's not possible though
Star
Discord
online
Get help straight from the Payload team with an Enterprise License.