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
3,437 questions with no upvoted or accepted answers
Filter by
Sorted by
Tagged with
1 vote
0 answers
456 views

Realm Migration not implemented correctly

I am using Realm in my Android apps and I would like to do the following: Make an existing field as Primary key. Change the type of field from int to String I wrote the following migration for the ...
itabdullah's user avatar
1 vote
0 answers
41 views

realm multiple classes error opening istance

I have a .realm file with 5 classes and I want to open that .realm file and read a column of one class but when I try to access the database I receive an error. It's an app for Android made in react ...
Didone's user avatar
  • 11
1 vote
0 answers
159 views

Storing a generic subclass in Realm

I have been trying to abstract a little bit my Realm models, so I wanted to create a superclass model with a generic type. Then, create subclasses for the specific type. I know Realm does not support ...
Sarquella's user avatar
  • 1,139
1 vote
0 answers
267 views

Realm React-Native Auth0: The provided credentials are invalid or the user does not exist

I have started using Realm not long and I am trying to integrate a authentication workflow inside my RN app, using various tutorials, documentations. (I was using the nickname provider until now). So ...
Richard Houet's user avatar
1 vote
0 answers
246 views

nativescript cocoapods plugin for RealmIO and typescript

I am trying to port two native implementations of an app, to a single version based on nativescript. The android app used SQLite, and the iOS used RealmIO for whatever reason. To read the iOS data, ...
Soraz's user avatar
  • 6,680
1 vote
0 answers
190 views

How to Use One Realm Object from another Realm Object?

I have two realm Objects, one is Booking and Guest.below is the sample objects. open class Booking: RealmObject() { @PrimaryKey var id:Int = 0 var guest: Guest? = null } open class Guest: ...
Rajesh's user avatar
  • 531
1 vote
0 answers
193 views

Using NSTableView with cocoa binding and Realm

I am using NSTableView with cocoa binding. The Array which is binding with my table is causing an issue when I tried to save it to Realm. Error : Error Cannot add an object with observers to a ...
user3722523's user avatar
  • 1,750
1 vote
0 answers
1k views

io.realm.exceptions.RealmException: Dog is not part of the schema for this Realm

I create a Realm model and tried to save the value in the realm. But Realm throws "RealmModelClassName" is not part of the schema for this Realm I tried various method which is suggested in ...
JEGADEESAN S's user avatar
1 vote
0 answers
150 views

which database provide easy Encryption of data? realm vs greenDao vs (room+saferoom) vs (sqlLite+cipher)

currently, in our Project, we are using sqlLite+cipher old school method for storing in database and encryption. we planning to rewrite need advice on what to use for database+encryption our app is ...
vijay surya's user avatar
1 vote
1 answer
40 views

Problem with search Filter in my Database

I have a search bar that search in all of my database. searchView.setOnQueryTextListener(new SearchView.OnQueryTextListener() { @Override public boolean onQueryTextSubmit(String s) { return ...
Majidd74's user avatar
1 vote
1 answer
192 views

react native realm crashed after start

I just tried to get started with react-native and realm. Followed the tutorial here: Tutorial from realm I did nothing, just - react-native init demo - cd demo - npm install realm --save - react-...
Matt's user avatar
  • 11
1 vote
0 answers
356 views

Android, Realm, Kotlin check RealmObject has field matching variable, set RealmObject key with variable

So I have booleans in SharedPreferences in Android. I want to conditionally update the booleans in my Realm instance in the onPreferenceChanged listener. Some of the booleans are matched in the Realm ...
Tom's user avatar
  • 1,487
1 vote
1 answer
819 views

How to migrate RealmJS db after change the column type?

I'm using realmjs DB in my react-native app where I have a schema settings. I want to change a property type of that schema from int to string. So I understand that I need to perform migration and I ...
Julfikar's user avatar
  • 1,403
1 vote
0 answers
31 views

Android studio changes for Realm Object Server migration from 2.x to 3.x

I am an android developer, but new to Android Studio and Realm. I have a working app on ROS 2.x and android client with realm-gradle-plugin 4.3.4. In my project I have a requirement for ROS ...
9bell's user avatar
  • 11
1 vote
0 answers
88 views

Building realm from Source and using AAR in Android project

I have built the Realm-Java from the source and generated below files as per the Offlicial-doc a jar file for the Realm Gradle plugin an aar file for the Realm library a jar file for the ...
Adi's user avatar
  • 425
1 vote
0 answers
59 views

React Native Realm filter item in list of type strings property

I have the following schemas/models, and I want to query where Employee->specialization is contains "java". Here's my schema: export class Employee { } Employee.schema = { name: 'Employee', ...
Rocky's user avatar
  • 3,167
1 vote
0 answers
439 views

Request all data from realm cache and keep data updated - iOS App Architecture

I'm updating data from multiple locations in my app. How can I keep data updated on all views? I’m developing an app which contains a timeline, where you can see the posts from people who you are ...
Aitor Salvador's user avatar
1 vote
1 answer
384 views

Realm doesn't always return an object for its primary key from the cloud, although it does exist there

I am quite new to Realm and now I'm facing the issue, mentioned in the title. Basically, one of my Realms is a User class (this is different from Users that is created when new users log in) in Realm ...
Tigran Iskandaryan's user avatar
1 vote
0 answers
396 views

Android Realm Migration Issue → java.lang.IllegalArgumentException: Primary key field 'foo' cannot be changed after object was created

During a Realm migration on Android, I am attempting to uppercase an existing String field but getting the following error because the field is a primary key. java.lang.IllegalArgumentException: ...
Steve Yohanan's user avatar
1 vote
1 answer
2k views

Sorting a List in Realm Swift

I have a List of objects, which I need to sort by a date property. I'm using that list to display the items in a UITableView My problem is that, sorting a List in Realm returns a Results<myItem>...
amirfl's user avatar
  • 1,644
1 vote
1 answer
702 views

Making sense of Realm, Moya, and ObjectMapper

So I'm trying to make sense of how to use Realm, Moya, and ObjectMapper. I use Moya to make requests to my API. I use Realm to keep the returned data in a local database. And I use ObjectMapper to ...
user6724161's user avatar
1 vote
1 answer
253 views

Store non realm object into realm database

I have a third party library which has lot of data model created to capture the data in object. For example, to store record they have Record class, to store glucose readings they have Diabetes class. ...
Hunt's user avatar
  • 8,305
1 vote
1 answer
103 views

Storing Arraylist<Double> into Realm database

Is it possible to store ArrayList<Double> into Realm database, and has anyone an example ? Thanks!
user avatar
1 vote
0 answers
779 views

Realm integration with Laravel

I'm working on a project which requires a real-time sync database feature. To achieve this task we are using Realm.io (Cloud Database) which supports native SDKs for iOS, Android, React-Native, .Net ...
Waqas Ghouri's user avatar
  • 1,109
1 vote
0 answers
649 views

Java Realm MissingLibraryException

Keep getting the following error on the line where I Realm.init(this) java.lang.RuntimeException: Unable to start activity ComponentInfo{uk.app/uk.app.LoginActivity}: com.getkeepsafe.relinker....
Lewis Smith's user avatar
  • 1,305
1 vote
0 answers
45 views

scaning bluetooth (java) on android studio

I am developing the attendance system using Bluetooth that allow the user to scan Bluetooth to get the Bluetooth address and compare it with registered Bluetooth address. The problem is, it only scan ...
Alia Azmee's user avatar
1 vote
0 answers
126 views

Realm database in production

I developed an application using Realm database with user authentication via iCloud token. Now I want to publish my application to the App Store and need to deploy Realm to the production. My ...
Martin Žid's user avatar
1 vote
0 answers
356 views

How to use lifecycleObserver for ON_CREATE before the method is called

I use RealmDB and per the documentations, the best practice is to get an instance of the DB on "onCreate" methods and clear it on "onDestroy", so far so good - I've done that. Since we have multiple ...
MichaelThePotato's user avatar
1 vote
0 answers
196 views

How to fix Error when committing to Realm

I am developing android app that uses Realm as Database but i get an error when excuting commitTransiction() method in Relm this is the method that make a crash if (food!= null) { foodDb....
Alpha Net's user avatar
1 vote
0 answers
217 views

Not delete embedded objects from Realm

Android Studio 3.2. Realm 5.8.0 public class Merchant extends RealmObject { @PrimaryKey private long id; private Image preview; } public class Image extends ...
Alexei's user avatar
  • 15.1k
1 vote
0 answers
66 views

Insert or update realm content based on objects inner attribute changes

My data model looks like this: Dummy: id: String title: String content: List object1 object2 object3 ... Lets image I've a table "Dummy" in realm, where I have 4 Dummy objects. I do a sync from ...
MaaAn13's user avatar
  • 328
1 vote
0 answers
194 views

RealmSwiftPermission' is not managed by the Realm

In my Realm Cloud, I have Realm Locations where I store locations for my map. Every user should have access to this Realm and get through query nearest annotations. But I faced with a problem: Only ...
Алишер Иглымов's user avatar
1 vote
0 answers
32 views

Can't init list in Realm

Android 3.2, java 1.7. Realm 4.1.0 Here code: public class LocalizedString extends RealmObject { private RealmList<TranslatedString> translations; public void cascadeUpdate(Realm realm, ...
Alexei's user avatar
  • 15.1k
1 vote
0 answers
160 views

Is it possible to update only one field to Realm?

Android Studio 3.2, Java 1.7, Realm 4.1.0 Here my pojo: public class ImageFormats extends RealmObject { private ImageSource reference; private ImageSource average; } public class ...
Alexei's user avatar
  • 15.1k
1 vote
0 answers
103 views

Use only one registered realm user on all devices

I am trying to make an app, first iOS then Android, which will have synced offline-first realm. Idea is to make changes in database through Realm Studio, and for all devices to sync with it when they ...
Robert's user avatar
  • 11
1 vote
0 answers
522 views

:app:transformClassesWithDexBuilderForDebug Exception after adding realm

I just added Realm to my project, which had worked fine before. After adding it started to throw when building : FAILURE: Build failed with an exception. org.gradle.api.tasks....
Roman's user avatar
  • 803
1 vote
1 answer
807 views

What happens if I put Dispatch.main.async block inside Dispatch.global.async?

I have a case where I am saving data to Realm Database inside Dispatch.global in background thread then inside same thread I have called Dispatch.main.async to fetch data from Realm and update ...
Manish Patel's user avatar
1 vote
1 answer
65 views

Writing to previous realm object instead of next

I'm completely new in Realm and I'm trying to add some data ty my database. I have a trainings which consist of exercises. Every training has id, date and list of exercises. In my table view I create ...
Michał Lewczuk's user avatar
1 vote
0 answers
144 views

Realm query problem with sorted localized data

Consider the following Realm models: class Fruit: Object { @objc dynamic var name = "" let localizations = List<Localization>() /** Returns the localized name of the fruit ...
Vin Gazoil's user avatar
  • 1,980
1 vote
0 answers
62 views

Cast Realm List to Array without expliciting its type

When using Mirror to iterate through an Object properties, how do I cast a List<Object> to Swift primitive array type [Object]? My code is structured as follow let mirror = Mirror(...
GGirotto's user avatar
  • 956
1 vote
1 answer
856 views

Getting invalid property name when trying to perform Realm migration

I'm having trouble with Realm giving me the error that a property of a given name does not exist for my object. But I know it does exist. I've tried to follow the docs at https://realm.io/docs/swift/...
Donavon's user avatar
  • 11
1 vote
1 answer
365 views

Update objects in RealmSwift?

I know that lot's of similar questions are around - I fear that my problem is on such basic level, that all the other question I could find, are much more complicated and yet, doesn't quite seem to ...
Anton Bjerg's user avatar
1 vote
0 answers
49 views

How to create a realm transaction on the same thread from several webservice results

We have a big amount of data to insert into a realm database. The data are coming from several webservices for a total amount of 100Mb to 1Gb. We need to store each result from network with a ...
Nicolas Lauquin's user avatar
1 vote
0 answers
141 views

ERROR ITMS-9000: “Unsupported architectures. Your executable contains unsupported architectures '[x86_64, i386]'”, error occurred

I received the following error when trying to upload my app to App Store -'ERROR ITMS-9000: “Unsupported architectures. Your executable contains unsupported architectures '[x86_64, i386]'”'. I have ...
Sidharth J Dev's user avatar
1 vote
1 answer
511 views

Mobx-persist with encryption

I am using mobx-persist library to persist data and I need to implement encryption since I am dealing with sensitive data. I know that AsyncStorage does not support encryption so my idea is using ...
Railan Xisto's user avatar
1 vote
0 answers
539 views

Android Kotlin: Realm many to one relation

I have trouble with the management with one-to-many relations between Kotlin objects using Realm. I don't understand how to do some insert or update. Here my two objects with one-to-many relation ...
Dennis A. Boanini's user avatar
1 vote
1 answer
47 views

realmswift : manipulate arrays with realm object

I am stucked with a problem in my app development. I have 2 objects, car and Conso. Conso : import Foundation import RealmSwift final class Car : Object { //@objc dynamic var ID = 0 @objc ...
P. Francis's user avatar
1 vote
0 answers
109 views

No preview with the downloaded image in ARKIT

I have been working on an ARKit app and I achieved my goal of detecting the pictures in the scene and playback video in the scene. The problem occurred is when I tried to fetch the image from the ...
J Singh's user avatar
  • 79
1 vote
0 answers
285 views

Predicate to find intersection of array of integer property with collection?

I have an object that has a List<Int> property: class Products: Object { dynamic var name: String = "" dynamic var price: Double = 0 dynamic var categories = List<Int>() } From the ...
TruMan1's user avatar
  • 34.7k
1 vote
0 answers
413 views

Query from RealmList<String> in RealmObject

I have a list of object of Product type as follows. public class Product extends RealmObject { @PrimaryKey private String productId; private String name; private RealmList<...
Nimila Hiranya's user avatar

1
14 15
16
17 18
69