Questions tagged [realm]
Realm, formally known as MongoDB Realm, is an object-oriented database widely used as an alternative to SQLite & ORMs that includes a built-in device-to-cloud data sync. Realm supports a variety of platforms including Android, iOS, Linux, macOS, and Windows.
realm
9,450
questions
0
votes
0
answers
7
views
Replace Realm DB in the an existing Android app with Room DB
We have a 4+ year android application that relies on the Realm DB. We are exploring the possibility to adopt the Room Database going forward. There are a few challenges and queries that need to be ...
0
votes
0
answers
13
views
Filtering query with BEGINSWITH of Realm database in Kotlin
I am having issues with a query which includes BEGINSWITH (or CONTAINS for that matter). I am trying to follow the example as found in the Mongo Db documentation:
This query to find instances of the &...
0
votes
0
answers
17
views
In Blockchain, who or what are the nodes in the real word? [closed]
when the blockchain is developed for the agri-food supply chain, who/what are the nodes? do they correspond to the stakeholders of this industry? thus, are the nodes the same as the companies involved ...
1
vote
0
answers
32
views
How to get an instances of saved realm objects in my SwiftUI DeviceActivityMonitorExtension point in the background?
I have initialized realm in the init of the @main app point like this:
init() {
let fileURL = FileManager.default.containerURL(forSecurityApplicationGroupIdentifier: "group.com....
0
votes
0
answers
17
views
Polymorphism on Realm (React Native SDK)
I'm new to Realm and hit a bit of a snag when it comes to implementing a polymorphic design on a React Native.
Basically, I'm trying to figure out the best way to manage different entities that can ...
0
votes
1
answer
22
views
How to enable admin user of master realm
KeyCloak Admin user of the master realm has been disabled my mistake. How can I enablae it ?
Expecting to enable the admin user so that I can login back.
Not sure if the user enable is happening ...
0
votes
1
answer
20
views
How to create multiple realm models in flutter and mongodb realm
I am new to flutter and realm. I have multiple forms in my project and I wanted to know what the best way to create the models is. I am working on a flutter app using the latest realm and flutter ...
0
votes
0
answers
19
views
Realm v12.6.2 with React Native v0.73.5, getting link error in iOS build compile
While adding the latest Realm node module v12.6.2, there is a bug from iOS app, linking issue.
Please suggest the workaround / solution to this issue.
Realm React Native iOS link error - Screenshot ...
0
votes
0
answers
33
views
Realm Flexible device sync while client is offline. (React native SDK)
I have a scenario where I need the application user to be able to log in while online. After logging in, the sync should be paused on the client side. The user should then be able to use the app ...
0
votes
0
answers
15
views
Unable to initialize my MongoDB app since syncrootdirectory is null
I am unable to initialize my MongoDB App as my appfilesdirectory in building the app is null (i.e getting NullPointerException). How would I be able to fix this? I tried updating to the latest android ...
0
votes
1
answer
27
views
Realm : Generic parameter 'Element' could not be inferred
I'm trying to use "Realm" with a few lines of code found on "stackoverflow".
I get an enigmatic compilation error:
Generic parameter 'Element' could not be inferred
on the line: ...
0
votes
1
answer
46
views
Adding Realm Kotlin as a dependency in an Android Library
I'm trying to add Realm Kotlin to an Android Library module by following the steps outlined here https://www.mongodb.com/docs/realm/sdk/kotlin/install/#add-the-sdk-to-the-project. However I see that ...
1
vote
1
answer
50
views
Do I need to perform a migration block when updating @PersistableEnum?
I have a realm model setup like this:
enum RealmEnumExample: String, Codable, PersistableEnum {
case hot, cold, cloudy, rainy
}
final class RealmExample: Object, ObjectKeyIdentifiable {
@...
0
votes
0
answers
36
views
Is there a size limit for database file in Realm Swift?
My iOS app uses Realm as its local database.
Various data generated by the app is saved in the default.realm file.
In tests using actual devices, when the size of default.realm exceeds about 6GB, ...
0
votes
0
answers
42
views
realm throws error that object was deleted
I need to delete object from realm. But when I do that, it throws an error:
Terminating app due to uncaught exception 'RLMException', reason: 'Object has been deleted or invalidated.'
Here is my ...
0
votes
0
answers
32
views
How to save records in a multi model Ream database?
I have a project that uses 3 Realm models: Pantry, Department and Market. The Pantry and Department have a 1 to many relationship and the Pantry and Market have a many to many relationship, and all 3 ...
0
votes
0
answers
43
views
Getting an error with react native, expo and realm saying " Error: Getting '$$typeof' from binding before it was injected " How do I stop this?
So I am trying to use realm in my expo project, so I did the command npx expo prebuild and got the android folder installed in my project. I runned the code and recieved the error 'Error: Getting '$$...
2
votes
1
answer
134
views
Web Assembly (WASM) errors in a Vite + Vue app using Realm Web SDK
I'm using MongoDB Realm / App Services to make a web front end for an existing iOS app.
The standard Realm Web SDK only permits authentication and backend functions, so I am trying to use the preview ...
0
votes
0
answers
31
views
Kotlin MongoDB Realm flow collect cannot pass param to query
I'm in stuck.
I have Realm database. In viewmodel I receive data as a flow. In Fragment collect it.
Problem is when i want to filter / pass a param to realm query - there is no changes.
Viewmodel code:...
0
votes
1
answer
96
views
Cannot find 'assumeOnActorExecutor' in scope
After install realm i got 4 errors 🙁
I coudn't find a solution any where and here the error message: Cannot find 'assumeOnActorExecutor' in scope
See screen shot
Help pleaseenter image description ...
3
votes
0
answers
34
views
Cannot get the updated value in MongoDB realm
I have this function on the server said that updates some values for my user:
exports = async function(userId, district){
var userCollection = context.services.get("mongodb-atlas").db(&...
0
votes
0
answers
46
views
React Native Expo Realm template not working
I am trying to learn React Native with Realm.
I installed the default template with:
npx create-react-native-app --template with-realm ExpoRealm
Then I tried to run it with:
npx expo run:android
It ...
0
votes
1
answer
62
views
Error in Declaring Non-Optional Map Property in Realm Swift Object
I have this realm object with a map property:
class UserModel: Object {
@Persisted var uploadMap = Map<String, UploadingModel>()
}
where UploadingModel is another realm object.
once I ...
0
votes
0
answers
38
views
Removing all rows in a List (with a Realm datasource)?
I'm having problem with my app crashing when deleting all data of a specific type in Realm. The data is made available to the view through a @Published var in my "RealmManager". It looks ...
0
votes
0
answers
23
views
.Net Realms Assertion failed: !realm.is_in_transaction() turn on backtrace
I'm using Realms on .Net and I get the error
The active test run was aborted. Reason: Test host process crashed : D:\a\realm-dotnet\realm-dotnet\wrappers\realm-core\src\realm\object-store\impl\...
1
vote
1
answer
93
views
How can I read data from a Realm Query in Jetpack Compose?
I have a User query with data and I want to retrive the data inside it, but I can't do it, in the console log all it says me is this ,, StandaloneCoroutine{Completed}@55d57e3 "
I want to retrive ...
0
votes
0
answers
61
views
Realm Swift : Terminating app due to uncaught exception 'RLMException', reason: 'Attempting to access an invalid object'
I'm new into iOS development, I am using Mongo Realm Swift library in my SwiftUI App.
I have 2 classes WhatsNewQuiz and ImageUrlHolder.
I am downloading WhatsNewQuiz items from the server and loop ...
0
votes
1
answer
70
views
Realm: @Persisted(primaryKey: bool) migrated from static func primaryKey()
I am in the process of removing all @objc dynamic annotations from Realm objects to use the more modern @Persisted annotation.
While it's been good for a lot of the code, I am running into issues, one ...
0
votes
0
answers
27
views
Realm Swift Migration: How to see if property/key exists?
I've got a iOS based realm app that has gone through a number of schema changes. For one schema version (version 36), I added a property named "activationStartGameTime" as a swift ...
-1
votes
1
answer
34
views
Realm Studio - Durability not consistent
When I open the default.realm file for a flutter app that is currently running on an iOS simulator, I get the messages "Durability not consistent" and "No schema selected". Is ...
0
votes
1
answer
77
views
Does Realm use a cached instance when repeatedly instantiating Realm?
I have a Swift & SwiftUI app using Realm for data persistence. In my code, I am instantiating a new Realm instance each time I need to access the database, like this:
final class RealmDataManager {...
0
votes
0
answers
42
views
How to make a wrapper for Realm that won't crash when used on different thread?
I am creating a wrapper for Realm so I can test my app easily with mocks. This is the code:
import Foundation
import RealmSwift
import Realm
class RealmStorage: LocalStoring {
private static let ...
0
votes
1
answer
58
views
Version of Package in Xcode Swift Package Manager
My SPM detail in Xcode says 12.12.0 of RealmSwift is loaded, but when my app accesses Realm, I get the message that 10.46.0 is available. Is that just information or do I misunderstand what Xcode ...
1
vote
0
answers
44
views
What are the requirements for the reset password page for Realm Mongodb?
I have set up user creation and authentication for a .net maui app using MongoDB and Realm, and it works brilliantly. I am struggling a bit with the reset password function. I have opted to use the “...
0
votes
1
answer
62
views
Can @Persisted property be also @objc in Realm
Realm database offers, since version 10.10.0, to declare stored properties with @Persisted annotation, replacing the @objc dynamic annotation.
The documentation is pretty clear about the transition: ...
0
votes
1
answer
22
views
Realm migration in swiftui doesn't get called
Firstly I use shared instance outside SwiftUI
let realm:Realm!
let container = FileManager.default.containerURL(forSecurityApplicationGroupIdentifier: ProjectSettings.group)!
static let shared = ...
0
votes
0
answers
49
views
MongoDB Atlas Device Sync (App Services) - React Native
i am building a react-native-app with MongoDB - App Services as backend.
Everything worked fine already, until i added a custom schema object type (User_location). The SDK don't want to accept it.
...
1
vote
0
answers
63
views
Installation problem with Realm in Flutter for IOS platform
We started a Flutter project few weeks ago and want to use Realm for local storage. But it’s not working on IOS simulator or real device.
We are using this configuration for Flutter and Dart:
Flutter ...
0
votes
0
answers
46
views
React Native Realm Migration: Proper way to set value of a property in migration
Hi I am new to realm.
I have a Realm Object with a boolean property whose default value set to false (let's call this schema version 1).
Person.schema = {
primaryKey: 'id',
properties:{
working: {...
1
vote
0
answers
162
views
Realm in SwiftUI: Index out of bounds error after delete when using @ObservedSectionedResults
When I add multiple notes and try to swipe to delete them, the app crashes and displays this error message:
Thread 1: "Index 3 is out of bounds (must be less than 3)."
import SwiftUI
...
0
votes
0
answers
26
views
Schema validation failed - Mongo db atlas device sync
I want to use the Atlas device sync feature of Mongo DB in my Application. I have modeled a BankAccount class in my Kotlin code like this.
open class BankAccount: RealmObject, Searchable {
@...
0
votes
0
answers
52
views
Realm local data base is very slow when writing and reading big objects/ React Native App Hangs
I am trying to write data in realm that i am getting from a BLE listener. 6000 objects in 10 to 20 seconds i tried to write all the objects in realm but it was very slow and taking much more time so i ...
0
votes
0
answers
34
views
Main app cannot find a pod used by custom shared framework
I have a main app "authenticator" that uses a custom framework "storage". The "storage" use RealmSwift to handle any CRUD functionality and being used by the main app and ...
0
votes
0
answers
18
views
Using Realm, and JavaScript how do I access data in Atlas
I am attempting to incorporate Realm into a mobile app and am able to successfully use authentication:
App.jsx
...
export default AppWrapper = () => {
return (
<AppProvider id={"...
1
vote
0
answers
41
views
Realm documentation says that there is user object which contain flexibleSyncConfiguration method but actually it doesn't exist
below I will try to use user.flexibleSyncConfiguration, but it does not exit , but documentation. says it is, I use latest realm sdk 10.44.
What is the issue over here?
@MainActor
func openSyncedRealm(...
0
votes
0
answers
32
views
MongoDB Realm / App Services Swift Login Synchronisation not working, Users need to login every time
I've build an SwiftUI App that uses MongoDB Realm (or now App Services) as a backend. Users can authenticate using email/password, AppleID or Google.
In the docs and by mongoDB it says that realm ...
1
vote
1
answer
110
views
dyld[13932]: Symbol not found: _OBJC_CLASS_$_RLMApp and crashes
Using Xcode 15.1 and Realm 10.44.0 ( I tried 10.45.3 as well), my iOS app compiled but crash immediately at the start.
I get this message in the console:
dyld[13932]: Symbol not found: _OBJC_CLASS_$...
1
vote
1
answer
61
views
Issue while deleting a cartItem in realm
In this view if I tried to send another view like CartItem() then the app get crash and the error Thread 1: "Object has been deleted or invalidated." if I again get into the app the cartitem ...
0
votes
0
answers
79
views
React-native: realm. UserProvider fallback component not rendering when user is not logged in
Im working on a react-native expo app and have installed realm to implement mongo-db login.
my code is:
App.tsx:
import { StatusBar } from 'expo-status-bar';
import { Text, View } from 'react-native';
...
0
votes
0
answers
46
views
Struggling to Save Large JSON Data in Local Storage Using Realm in React Native
I'm encountering the Row too big to fit into CursorWindow error when trying to save a large JSON dataset using Realm in my React Native app.
const Save = storeName => async (key, value) => {
...