Block or Report
Block or report slugcat-dev
Report abuse
Contact GitHub support about this user’s behavior. Learn more about reporting abuse.
Report abusePinned
-
How I Restored My Database from a Me...
How I Restored My Database from a Memory Dump.md 1# How I Restored My Database from a Memory Dump
23Yesterday evening, I was coding on my free-time project and dared touching some back-end code and a database schema.
45I wanted to rename a key in a collection from `created` to `createdAt`, nothing complicated; Renaming a key in MongoDB normally is as simple as calling `Schema.updateMany({}, { $rename: { oldKeyName: 'newKeyName' } })`, but for some reason it didn't work. After [going through the docs](https://mongoosejs.com/docs/timestamps.html), I found out this was not possible for that specific key name:
Something went wrong, please refresh the page to try again.
If the problem persists, check the GitHub status page or contact support.
If the problem persists, check the GitHub status page or contact support.