简体   繁体   中英

Can't save changes in Realm DB file

I work in iOS app and I use Realm for local DB. I've installed Realm via cocoapods and added my model classes. Everything is fine but when I opened the default.realm file from the simulator Documents directory in Realm browser app, I was unable to edit records or do any changes. I'm able only to add records but I can't edit fields, once I put the value in fields and navigate between classes, all changes I made disappear.

Update: I see in cocoapods, the RealmSwift installed is version (0.98.3) and the Realm browser which is the latest from App Store is version Version 0.97.0 (62) . Would that be the problem?

If you double-click on a field, that should make the cell editable and you can change it's values. It might be necessary to hit 'Return' after you've made those changes for the value change to stick.

There's a new version of the Browser on its GitHub page now: https://github.com/realm/realm-browser-osx/releases/tag/0.98.3

If you're still having issues with that version and the instructions I provided above, please let me know here!

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM