isar / isar/hive

Updating hive Object based on value

Open
#601 2 comments 0 reactions 0 assignees View on GitHub
question
Dominant language
Dart
Stars
4.4k
Forks
449
PR merge metrics
No merged PRs in 30d

Description

**Question**
I am trying to update table based on an id not on its position, is it possible in hive 2.0

**Code sample**
Future CheckUpdate(int product_id, BuildContext context) async {
Box prodBox = await Hive.openBox(ProductTable);
final modelExists = prodBox.containsKey(product_id);

if (!modelExists) {

} else {
}
}

**Version**
- Platform: iOS, Android, flutter
- Flutter version: [2]
- Hive version: [2.0.0]

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.