129 questions
0
votes
1
answer
61
views
Is there any way to treat an old deleted property and a new property with the same name (but different UID) as the same property in database?
I had this property named reminders in my Task entity.
String? reminders;
then I deleted it to migrate it to use List<String> instead, unfortunately I realized this later that to migrate the ...
3
votes
1
answer
416
views
Error: The method 'getInvocation' isn't defined for the type 'DartObjectImpl'
Android Studio Latest, Flutter 3.35.6, sdk: ^3.9.2, Microsoft Windows 11 25H2,
Flutter Doctor without warnings.
Create a new Flutter project (Android & iOS) and without touching the generated code,...
2
votes
0
answers
51
views
Objectbox sort object using the sum in one to many relations
I am using objectbox for the database in my app. I have a one to many relation between my items and I want to sort my items based on that relation.
As an example I use these entities :
@Entity()
class ...
1
vote
1
answer
45
views
How to store objets to pre-populate objectbox database
I am using objectbox to store a database in my mobile app written in flutter. I have to pre-prolate the database at first launch with files provided in the .apk.
I tried using the data.mdb file ...
1
vote
0
answers
78
views
ObjectBox for Dart not lazy-loading ToMany relations separately
In the documentation for ObjectBox, they say
to-many relations are resolved lazily on first access, and then cached in the source entity inside the ToMany object.
In my app, I want to use a ToMany ...
1
vote
1
answer
133
views
Unable to ship my flutter app with a pre-built ObjectBox database
I'm unable to ship my Flutter app with a pre-built database. Below is my approach; it would be greatly appreciated if this intent of shipping a database and the steps involved are validated. Thank you....
0
votes
0
answers
17
views
Querying by count of elements in a tomany relation (How many customers with at least two orders?)
I'm new to ObjectBox so this question might be very basic, but I could not find an answer in the guides.
In the sample classes below, I would like to query all Customers that have at least 2 orders.
...
0
votes
0
answers
117
views
ObjectBox Cannot open store: another store is still open using the same path
I have a flutter app that uses ObjectBox to cache some data for offline availability.
I have an issue where if I swipe back on my android phone and the app goes to the background, when I open the app ...
0
votes
1
answer
107
views
ObjectBox select what to sync
I am just trying out ObjectBox and sync server.
I have a very simple sync scenario where I have multiple users for example user_A and user_B. Each user may have multiple devices, for example user_A ...
0
votes
0
answers
48
views
Flutter Object Box store image from URL
Does anyone know how we can store images obtained from a URL to object box ?
This is what i currently have:
@Entity()
class ServiceModel {
@Id()
int id = 0;
@Unique()
final String identifier;
...
1
vote
0
answers
58
views
ObjectBox Admin in Docker - Not refreshing UI data when db data are CRUDed
I am using ObjectBox Admin in Windows through WSL (Docker in WSL, using objectbox-admin.sh) and accessing a db file in Documents folder (shared with WSL).
From a browser I can access the contents in ...
0
votes
1
answer
77
views
Error 404 when saving object with relation in Objectbox after removing a ToMany relation
I use objectbox with Flutter for one of my project. I have two object link MyObject and InsideObject :
@Entity()
class MyObject {
@Id()
int id = 0;
String? name;
final insideObjects = ToMany&...
0
votes
1
answer
95
views
how to restore objectbox-model.json file after building
I'm using flutter with windows desktop and forget submit objectbox-model.json file to git. The App already run in the production envionment, how to restore the objectbox-model.json file working with ...
0
votes
1
answer
116
views
Flutter builds fail consistently when attempting to work with Flutter databases
I'm learning Flutter and focusing on Databases but have been unable to use them.
An error occurs after adding dependencies for Isar and ObjectBox databases, however Hive appears to work.
After adding ...
0
votes
1
answer
188
views
How to conditionally add a condition to my objectbox query?
I have this method to find all my Clientes:
static Future<List<Cliente>> findAll({
int limit = 50,
String? cnpjCpf,
String? fantasia,
}) async {
List<Cliente> clientes = [];
...
0
votes
0
answers
53
views
Unable to get expected result when performing relational queries using linkMany
I want to query a list of NoteCollectionEntity which does not contain a NoteEntity having an id of value id.
For context, here's the model definition for NoteEntity:
@Entity()
@CopyWith()
class ...
0
votes
1
answer
61
views
Managing relationships between entities by Many-to-Many link
I have 2 entities User and Location with a Many-to-Many link. The creation of a relationship seems to work but not the deletion.
The goal is not to delete the entities but only the relationships.
...
0
votes
1
answer
66
views
Am having setter error in Object Box flutter for a nested relationship
The setter 'target' isn't defined for the type 'LocationModel'.
Try importing the library that defines 'target', correcting the name to the name of an existing setter, or defining a setter or field ...
1
vote
1
answer
41
views
how to update only certain column/object in flutter objectbox?
I'm new to Flutter, how do I update certain objects/columns (not all columns)?
the table/entity class:
@Entity()
class Customer {
int id;
final String name;
final String city;
...
0
votes
1
answer
196
views
Objectbox flutter: watch limit
My question will seem quite simple but i have hard time to find anything about limit watch in objectbox.
box.query().watch(triggerImmediately: true).map((e) => e.find());
I was able to do it like ...
0
votes
0
answers
19
views
Cannot figure out default value for field: Salescategory salesCategory
cannot generate g dart file with flutter pub run build_runner build which class is shown below and getting this error just because of enum parameter:
enum Salescategory { sales, salesReturn, ...
3
votes
0
answers
190
views
Query using multiple links in Objectbox
I have these 2 entities in objectbox:
@Entity()
class Account {
@Id()
int id = 0;
}
@Entity()
class Transaction {
@Id()
int id = 0;
final fromAccount = ToOne<Account>();
final ...
0
votes
1
answer
157
views
Flutter ObjectBox Save nested ToOne ToMany Entities
I have the following entities:
@Entity()
class CategoryData {
CategoryData({
this.id = 0,
required this.catName,
});
@Id()
int id;
String catName;
@Backlink()
final subCats ...
0
votes
0
answers
51
views
Not able to assign value into objectbox model with relation in flutter
I have model class which is created using Json to dart conversion. When I use this class as objectbox model, I can't set the relation. If I set the relation then jsonTo, jsonFrom methods not working ...
0
votes
1
answer
388
views
Switching or migrating from local-only ObjectBox to ObjectBox Sync
Neither Firebase Realtime db or Atlas Realm support this, but it's not clear from the docs whether ObjectBox supports this.
What I want to do:
I don't want to require users to create an account to ...
0
votes
1
answer
85
views
How to loop through Flutter ListView tiles generated from an ObjectBox database?
I have a Flutter app which uses ObjectBox to store back-end data, which is a list of Product objects. I have created a ListView Tile widget to present the data called ProductTile. I generate a ...
0
votes
1
answer
129
views
ObjectBox Not downloading with Pod install and also on their Github Page
An attempt to download the Zip "ObjectBox-xcframework-1.9.1.zip" from their Github page does not download And also doing "pod install --verbose" didn't download it.
Turning on and ...
0
votes
0
answers
114
views
Sourcery.app artifact instead of Runner.app created during iOS build
I am using ObjectBox for Dart/Flutter. As per documentation, iOS requires objectbox_flutter_libs package. However, Adding objectbox_flutter_libs (or objectbox_sync_flutter_libs) to pubspec.yaml causes ...
0
votes
2
answers
904
views
ObjectBox Database & Internal Storage in Flutter Stops Working When You Update The App
I have a flutter application using ObjectBox as the database that's being stored in internal storage, and I ran into the problem of when I update the application version (for example version 1.0.0) to ...
0
votes
4
answers
893
views
UnsupportedError (Unsupported operation: Loaded ObjectBox core dynamic library has unsupported version 0.18.1, expected ^0.19.0)
I get this exception at the startup of the app.
UnsupportedError (Unsupported operation: Loaded ObjectBox core dynamic library has unsupported version 0.18.1, expected ^0.19.0)
Flutter 3.15.0-15.2.pre ...
1
vote
0
answers
79
views
Object Box and Graph Queries
With ObjectBox supporting documents / objects and relations, does it support graph queries? It seems other non-graph databases like MongoDB also have some graph database like support, but hadn't quite ...
0
votes
1
answer
469
views
Getting Error: Bad state: failed to create store: Cannot open store: another store is still open using the same path: "/data/..." error 10001
I'm trying to store data locally with ObjectBox in Flutter, and I started getting this error. Everything looks good according to the documentation, I'm unsure why I'm getting errors from the objectbox....
-2
votes
1
answer
90
views
May someone please assist me with this error?
I am trying to create a basic todo app in flutter using Objectbox as a database.
This is the error:
[ERROR:flutter/runtime/dart_vm_initializer.cc(41)]
Unhandled Exception: ObjectBoxException: failed ...
0
votes
1
answer
257
views
passing parameter to object box query
I am new to object box. I am struggling on finding a way to pass parameters to my query. i looked at the documentation but still struggling.
this is my code
late Stream<List<dynamic>> ...
0
votes
0
answers
180
views
Unit Testing Object Box for Flutter App in macOS is failing
While reading from object box for doing unit testing for flutter app in mac, it is giving error like
RangeError (byteOffset): Invalid value: Valid value range is empty: 0
It is coming for any call of ...
0
votes
0
answers
907
views
Flutter ObjectBox: Incoming index ID does not match existing UID
I'm dealing with an issue related to ObjectBox migrations. Whenever I make a name change to any property in the app, if I re-run the flutter pub run build_runner build command to re-build the ...
2
votes
1
answer
543
views
Flutter Objectbox how to fix "Read Only File System" Code 30?
I developed my app for Windows and it works perfectly fine. So after some time I tried to build it to Android, it come with an error
E/Box (30248): Storage error "Read-only file system" (...
1
vote
0
answers
149
views
Objectbox Sync with Fly.io
I would like apply objectbox sync to fly.io. In testing in local, it is fine with the docker command. But in deploying to fly.io, I have no opinion with how to work -model command in fly.io.
docker ...
1
vote
1
answer
2k
views
Unsupported operation: Loaded ObjectBox core dynamic library
I updated flutter from 3.5 to latest flutter 3.7.2
flutter --version
Flutter 3.7.6 • channel stable • https://github.com/flutter/flutter.git
Framework • revision 12cb4eb7a0 (6 ...
0
votes
1
answer
64
views
Does it matter which side of an ObjectBox Many to Many relationship the @Backlink annotation goes on?
The ObjectBox docs and my own empirical research have shown the @Backlink annotation should always be placed on the ToMany side of a One to Many relationship, but it is unclear to me if it matters ...
0
votes
1
answer
325
views
Objectbox flutter apple silicon emulator support
Does objectbox flutter support ios emulator on M1 macbooks?
I get this error despite following Getting started guide, however it works fine in CI which also runs on M1 chip (but against physical phone ...
1
vote
1
answer
335
views
In ObjectBox for Flutter, is there a way to compare two properties?
I'm new to using ObjectBox, so I've been trying to do some experimenting with its query system to familarize myself with it. One of the queries I've been unable to do is a query comparing two ...
1
vote
0
answers
486
views
Dart - Export data from objectbox to firebase
Hi i need export the data created by objectbox to firebase. How could I do it if it is saved in a .mdb file, any ideas?
0
votes
1
answer
478
views
Flutter ObjectBox: Is List<String> supported for property converters?
The Flutter ObjectBox docs state:
ObjectBox (Java, Dart) has built-in support for String lists. ObjectBox for Java also has built-in support for String arrays.
However, using a List<String> in ...
1
vote
1
answer
805
views
Flutter with Equitable and ObjectBox: ToMany relationship not updating properly
I have the following classes:
import 'package:equatable/equatable.dart';
import 'package:objectbox/objectbox.dart';
@Entity()
/*
All fields of a class which extends Equatable should be immutable, but ...
0
votes
1
answer
145
views
Is there an objectbox condition, that can filter by string length?
Can I make a database query, with a condition that filters out any elements when a text field doesn't have length 2 or 3 characters?
0
votes
2
answers
148
views
Query with order, places accented value at the end
In my flutter project, I use box.query(myquery)..order(Kategoriak_.cikkcsoportnev).build(),
but my Áramfejlesztők, szivattyúk category is at the end of the list.
How can I order it correctly, so Á ...
1
vote
1
answer
1k
views
Streaming data from local ObjectBox (or Hive) database in a Clean Architecture Style
Maybe someone else has the same issues as I had, so here is how I implemented it, finally. I am showing this for ObjectBox, but some of the methods work for Hive or other databases as well.
My issues ...
1
vote
1
answer
803
views
How to get data from a relation in an entity in ObjectBox
I'm new to ObjectBox.
I have a worklistDocumentNumber, from which I need to get report master data by using query. Can anyone help me with this. I tried by adding some filter conditions in query, but ...
0
votes
1
answer
112
views
How to change query condition (not parameter)?
I want to reuse queries, and I know it is possible to change parameter, but how does one change the condition?
And do we have to always call query.close()?