NoSQL Database Storage | Flutter ObjectBox (vs Sqlite, Sqflite, Hive)

Sdílet
Vložit
  • čas přidán 27. 07. 2024
  • Persist data with Flutter's ObjectBox Database locally on your Android or iOS device. Perform CRUD operations: Create, Read, Update, Delete.
    Click here to Subscribe to Johannes Milke: czcams.com/users/JohannesMilke...
    👉 12 Week Flutter Training | heyflutter.com
    👉 Flutter Masterclass Courses | heyflutter.com/masterclass
    Source Code | github.com/JohannesMilke/obje...
    ObjectBox SyncServer Docs: sync.objectbox.io/objectbox-s...
    ObjectBox Package: pub.dev/packages/objectbox and github.com/objectbox
    ObjectBox Docs: docs.objectbox.io/
    My Courses | heyflutter.com
    Follow Newsletter | johannesmilke.com/#/newsletter
    SUBSCRIBE HERE
    bit.ly/JohannesMilke
    SUPPORT & SPONSOR ME
    github.com/sponsors/JohannesM...
    TIMELINE
    0:00 NoSQL Database | Flutter ObjectBox
    0:54 Setup ObjectBox for Android & iOS
    1:25 Initialize ObjectBox Database
    2:05 ObjectBox Database CRUD Operations
    3:27 ObjectBox SyncServer
    SOCIAL MEDIA: Follow Us :-)
    Twitter | / heyflutter_
    Linkedin | / heyflutter
    #Flutter #Tutorial #JohannesMilke
    LIKE & SHARE & ACTIVATE THE BELL
    Thanks For Watching :-)
  • Věda a technologie

Komentáře • 102

  • @HeyFlutter
    @HeyFlutter  Před 2 lety +5

    This might help you :)
    👉 12 Week Flutter Training from Newbie to Expert: heyflutter.com
    Source Code: github.com/JohannesMilke/objectbox_flutter
    ObjectBox SyncServer Docs: sync.objectbox.io/objectbox-sync-server#docker-distribution
    ObjectBox Package: pub.dev/packages/objectbox and github.com/objectbox
    ObjectBox Docs: docs.objectbox.io/
    Publish App On PlayStore Tutorial: czcams.com/video/g0GNuoCOtaQ/video.html
    Deploy Web App Tutorial: czcams.com/video/xJo7Mqse960/video.html
    Google Sheets API Tutorial: czcams.com/video/3UJ6RnWTGIY/video.html
    QR Code Tutorial: czcams.com/video/hHehIGfX_yU/video.html
    Delivery App Tutorial: czcams.com/video/fg2aLXNG0Bc/video.html
    Google SignIn With Firebase Tutorial: czcams.com/video/1k-gITZA9CI/video.html
    Animated List Tutorial: czcams.com/video/E3SQOqUq8Mg/video.html
    Send Email In Background Tutorial: czcams.com/video/RDwst9icjAY/video.html

  • @furkanabbasioglu3221
    @furkanabbasioglu3221 Před 2 lety +1

    Bro you are improving your description skills day by day. Very very thank you!

    • @HeyFlutter
      @HeyFlutter  Před 2 lety +1

      Thank you, Furkan Abbasioğlu! 🙂

  • @HandsOnKnowledge
    @HandsOnKnowledge Před 2 lety

    Johannes you are the best flutter teacher on CZcams, I love your videos and have learned a lot from you. Thank you for all your hard work

    • @HeyFlutter
      @HeyFlutter  Před 2 lety +1

      You're very welcome!, Monsieur Ali! 🙂 Keep learning and keep supporting

    • @ahmedalsyed218
      @ahmedalsyed218 Před rokem

      بما انك فاهم ممكن تقولي افضلهم

  • @leoMC4384
    @leoMC4384 Před 2 lety +2

    Very interesting. I remember I tried Hive, I followed the tutorials and documentation but it didn't work. However I found a library called Sembast, it's a simple but quite powerful NoSQL database. It worked like a charm. 😀😀😀

  • @Leon-cm4uk
    @Leon-cm4uk Před 2 lety

    I really like your tutorials! They are very helpful! They helped me a lot when I started learning flutter nearly 9 months ago for project I'm working on 🙂.
    Btw. kind regards from NRW. I guess based on your accent that you are also german Johannes Milke?

    • @HeyFlutter
      @HeyFlutter  Před 2 lety

      Awesome, thanks a lot, Leon! 🙂👍 Yep that's a correct guess!

  • @DraskoSaric
    @DraskoSaric Před 2 lety

    As usual, great video! I have a question though: when you delete the user from the list, does the whole list get refreshed or only the item we changed, i.e. deleted in our case?

    • @HeyFlutter
      @HeyFlutter  Před 2 lety +1

      Thank you, Draško Sarić! 🙂. The whole list.

  • @EdgarHernandez-fb4uu
    @EdgarHernandez-fb4uu Před rokem

    alguien sabe porque esta app no me funciona en windows?

  • @musoxon_
    @musoxon_ Před 2 lety

    Awesome, thank you!

    • @HeyFlutter
      @HeyFlutter  Před 2 lety

      Thank you, Musoxon Pazliddinov! 🙂

  • @Gontran_
    @Gontran_ Před 2 lety

    Very Cool ! Thank you !

  • @romanhs4591
    @romanhs4591 Před 2 lety

    very cool tutorial, it would be interesting to learn how to synchronize more complex models with connections

    • @HeyFlutter
      @HeyFlutter  Před 2 lety

      Thanks, Roman HS! 🙂 Yep sure, might be interesting to do this in another ObjectBox video maybe in the future.

  • @SaiyanJin85
    @SaiyanJin85 Před 2 lety

    Hey Jonathan! Thank you for your video. Just a quick question, Is it ok to have multiple objectBox classes for different type of info, For example an objecBox class for users and an objecBox class for products. Is this the way to go?

    • @HeyFlutter
      @HeyFlutter  Před 2 lety

      Thank You SaiyanJin85! Follow this link: medium.flutterdevs.com/objectbox-a-nosql-database-for-flutter-dart-4aac33870c41
      I hope you will get your answer 🙂

  • @Sampelmind81
    @Sampelmind81 Před 2 lety +1

    Hello Johannes, thanks for this, as usually, clean and on the point tutorial! Iam searching for an firebase alternative and using at the moment hive locally and iam wondering that there is an even faster approach as hive! Can i use Object-Box on any kind of server or are they restrictions? Thanks!

    • @HeyFlutter
      @HeyFlutter  Před 2 lety

      Thank You Sampelmind81! Follow this link: pub.dev/packages/objectbox
      I hope you will get your answer 🙂

    • @cholasimmons
      @cholasimmons Před 2 lety

      Have you had a look at appwrite also?

  • @antonyaz3506
    @antonyaz3506 Před 2 lety

    thank you for your job!)

  • @hosseintasm4222
    @hosseintasm4222 Před 2 lety

    perfect. thank you 👍

  • @htcexplorersgnr
    @htcexplorersgnr Před rokem

    When I changed to ask version 21 showing error in line Gradlexcepion G with red under line in vs code in build.gradle. and also my after ruing build two files not created in lib folder

    • @HeyFlutter
      @HeyFlutter  Před rokem

      Thank you, lucky malethiya! 🙂. Try to provide enough details with yours question whenever you face any issue.

  • @shaabzz
    @shaabzz Před 2 lety +1

    Can you do a tutorial on how to save and showcase api data in hive database when app is offline...like make an offline news app in which when internet is not available,the data from database must be shown and update news when internet is available...

    • @HeyFlutter
      @HeyFlutter  Před 2 lety +1

      Thanks for the idea, Shabz! 🙂 I have added it to my list of ideas for future videos!

  • @user-dl2lp1bq6l
    @user-dl2lp1bq6l Před 2 lety +1

    how we can cache an api data locally and update whenever there is an internet

    • @HeyFlutter
      @HeyFlutter  Před 2 lety

      Thank You መዝሙር ለጌታ! Follow this link: stackoverflow.com/questions/61538377/saving-cache-from-api-response-on-flutter
      I hope you will get your answer 🙂

  • @HandsOnKnowledge
    @HandsOnKnowledge Před rokem

    How can I access object box in other screens? I see you used it in the main.dart file but what if I wanted to access it in another screen. How can I do that? Would I need to use a provider to make object box available to the whole app? Thank you

    • @HeyFlutter
      @HeyFlutter  Před rokem +1

      Hey, @tigerwoods4167 🙂 There are several ways, you can use providers also, but making it static or global will an easy workaround

  • @iveive4400
    @iveive4400 Před rokem

    Thanks for your sharing!, but i occur an error, can you help me to resolve it?
    Exception has occurred.LateError (LateInitializationError: Field 'objectBox' has not been initialized.)
    I tried to using ? to resolve this issues, still cannot fix...
    Thanks

    • @HeyFlutter
      @HeyFlutter  Před rokem

      Thank you ive ive, make sure to follow the tutorial step by step 🙂

  • @vishwateja266
    @vishwateja266 Před rokem

    Unsupported operation: Cannot create multiple Store instances for the same directory in the same isolate. Please use a single Store, close() the previous instance before opening another one or attach to it in another isolate.

    • @HeyFlutter
      @HeyFlutter  Před rokem +1

      Thank You vishwa teja! Follow this link: stackoverflow.com/questions/68519352/objectbox-dart-flutter-multi-isolate-access
      I hope you will get your answer 🙂

  • @janammaharjan2699
    @janammaharjan2699 Před 2 lety

    That’s great ..can we use it for using multiplayer gaming app just like in real time database ?

    • @HeyFlutter
      @HeyFlutter  Před 2 lety

      Thank You Janam Maharjan! Follow this link: levelup.gitconnected.com/top-5-local-database-solutions-for-flutter-development-6351cd494070#:~:text=Sqflite,excellent%20transaction%20and%20batch%20support.
      I hope you will get your answer 🙂

  • @abderrazakkenniche4995

    Hi, thanks alot
    Can you please make a video about using SQFLite on desktop for linux and Windows
    I think we must use sqfliteFFi but i could understand all well
    I hope u can help me

    • @HeyFlutter
      @HeyFlutter  Před 2 lety

      Thanks for the idea, AbdErrazak Kenniche! 🙂 I have added it to my list of ideas for future videos!

  • @teesl4240
    @teesl4240 Před rokem

    Hi Johannes, thanks for great tutorial always. Would like to know if ObjectBox provide security encryption like Mongo RealmDB?

    • @HeyFlutter
      @HeyFlutter  Před rokem

      Thank You Tee SL! Follow this link: objectbox.io/
      I hope you will get your answer 🙂

    • @teesl4240
      @teesl4240 Před rokem

      Thanks. Will you provide tutorial on Isar Flutter?

  • @tamrawii
    @tamrawii Před 2 lety

    hello, thanks for the tutorial. Well I've got this problem while using objectbox (Any solution please)
    StateError (Bad state: object put failed: 10001 Can not modify object of sync-enabled type "Tasks" because sync has not been activated for this store.)

    • @HeyFlutter
      @HeyFlutter  Před 2 lety +1

      Thank You Mohamed Chahine Tamraoui! Follow this link: stackoverflow.com/questions/70735518/bad-state-failed-to-create-cursor-10001-can-not-modify-object-of-sync-enabled
      I hope you will get your answer 🙂

  • @hrhr3300
    @hrhr3300 Před rokem

    Hello, good video tutorial, you are prob on of the best teachers of flutter out here! :)
    I have a doubt since I'm having a weird error
    when I got to the part where I need to run "Flutter pub run build_runner build" I get an error "objectbox_generator: generator on lib:$lib$: Failed to find package root from output directory, generated imports might be incorrect" I dont know what is causing it and it seems that this is not common since almost nothing comes out in the google search, any idea what might be the problem?

    • @HeyFlutter
      @HeyFlutter  Před rokem +1

      Thank You HrHr! Follow this link: stackoverflow.com/questions/72728415/objectbox-generator-warningfailed-to-find-package-root-from-output-directory
      I hope you will get your answer 🙂

    • @hrhr3300
      @hrhr3300 Před rokem

      @@HeyFlutter Thank you so much!

  • @MohanRaj-cp9lg
    @MohanRaj-cp9lg Před 2 lety

    How to create gallery app from local storage in flutter

    • @HeyFlutter
      @HeyFlutter  Před 2 lety

      Thanks for the idea Mohan Raj 😀, i have added it in my list of future videos

  • @mdshahidali3132
    @mdshahidali3132 Před 2 lety

    Please Create a Video on How we Show Change Data or Normal Data in All Device , Suppose if we send images in android then and open in iOS Then it Show There Images .

    • @HeyFlutter
      @HeyFlutter  Před 2 lety

      Thanks for the idea, Md Shahid Ali! 🙂 I have added it to my list of ideas for future videos!

  • @livecricket2748
    @livecricket2748 Před 2 lety

    sir how to close store and use two screen with store data object box plz help me

    • @HeyFlutter
      @HeyFlutter  Před 2 lety +1

      Thank You Live Cricket! Follow this link: tutorialmeta.com/question/how-properly-use-the-objectbox-flutter-store-opening-and-closing
      I hope you will get your answer 🙂

    • @livecricket2748
      @livecricket2748 Před 2 lety

      @@HeyFlutter thanks

  • @__mothership__8475
    @__mothership__8475 Před 2 lety

    Hi Johannes, suggest me on How to update data in firebase for next day . I want data in firebase to change after 12AM in night, the map will be same but the values will be updated. How to do it without clicking any button becuase it has to be done for all users of app. HELP

    • @__mothership__8475
      @__mothership__8475 Před 2 lety

      @johannes or anyone from comment section help please

    • @HeyFlutter
      @HeyFlutter  Před 2 lety

      Thank you, Vipul Ghate! 🙂 you can take some help from server there is something called crone which is basically a scheduled program operates from server after particular interval of time

  • @obeddougan1505
    @obeddougan1505 Před 2 lety

    Please how can I store video or image file to objectbox storage

    • @HeyFlutter
      @HeyFlutter  Před 2 lety +1

      Hey, Obed Dougan 🙂 it is not suggested to store image inside local DB instead you should prefer local storage to store image and in DB just store the file path

    • @obeddougan1505
      @obeddougan1505 Před 2 lety

      @@HeyFlutter please if I may ask, can I store them on the online objectbox server like firebase has cloud storage

  • @jayamuruganj5091
    @jayamuruganj5091 Před 2 lety

    hi bro, i am having the following error, ( Bad state: failed to create store: 10001 Can not modify object of sync-enabled type "User" because sync has not been activated for this store.)

    • @HeyFlutter
      @HeyFlutter  Před 2 lety

      Thank You Jayamurugan J! Follow this link: stackoverflow.com/questions/70735518/bad-state-failed-to-create-cursor-10001-can-not-modify-object-of-sync-enabled
      I hope you will get your answer 🙂

    • @safdarali9226
      @safdarali9226 Před 2 lety

      Hi Johannes I tried below But same error.
      I use objectbox_sync_flutter_libs instead of objectbox_flutter_libs in pubspec.yml
      But this is not working for me.

    • @hasanibrahim4887
      @hasanibrahim4887 Před rokem

      @@safdarali9226 hello brother, im facing the same problem, I tried : objectbox_sync_flutter_libs instead of objectbox_flutter_libs, but I still have the same error, can you please share how you solve it? thank you

  • @mdmostafijurrahman1137

    Brother. I am trying to work with AR(Augmentation reality).
    I fetch some issue to show .glb file. Its never render. I want if you can provide one video about AR for android it will be many things for me

    • @HeyFlutter
      @HeyFlutter  Před 2 lety +1

      Thanks for the idea, 38-086-MD Mostafijur Rahman! 🙂 I have added it to my list of ideas for future videos!

    • @mdmostafijurrahman1137
      @mdmostafijurrahman1137 Před 2 lety

      @@HeyFlutter thank you so much

  • @Apenschi
    @Apenschi Před 2 lety

    What about complex queries? I doubt that ObjectBox will be faster with real world data models and queries! What about integrity rules? Triggers? What about write conflicts? Does it index all fields? Does a search results in a full table scan? How can you decide, which indexes to create? How big are the databases compared to SQFlite?

    • @HeyFlutter
      @HeyFlutter  Před 2 lety

      Thank You Apenschi! In the future I might create a video about ObjectBox complex queries etc.
      Follow this link: pub.dev/packages/objectbox I hope you will get your answer 🙂

  • @hashankannangara8723
    @hashankannangara8723 Před 2 lety

    thanks!!

  • @mohammedaymen8542
    @mohammedaymen8542 Před rokem

    Perfect

  • @AK-pt1ih
    @AK-pt1ih Před 2 lety

    Can I store multiple classes of data with this? If yes how?

    • @HeyFlutter
      @HeyFlutter  Před 2 lety +1

      Thank You AK 47! Follow this link: stackoverflow.com/questions/68436086/flutter-objectbox-does-it-work-to-have-multiple-mn-manytomany-relations-and
      I hope you will get your answer 🙂

    • @AK-pt1ih
      @AK-pt1ih Před 2 lety

      @@HeyFlutter Thank you!

  • @MohanRaj-cp9lg
    @MohanRaj-cp9lg Před 2 lety

    Gallery app from local storage

  • @golfgolf7161
    @golfgolf7161 Před 2 lety

    ObjectBox is some like Firebase?

    • @HeyFlutter
      @HeyFlutter  Před 2 lety +1

      Thank You Golf Golf! Follow this link: medium.flutterdevs.com/objectbox-a-nosql-database-for-flutter-dart-4aac33870c41
      I hope you will get your answer 🙂

  • @ThomasHankins
    @ThomasHankins Před 2 lety

    Wow I just added an sqflite database to my app, but this is so much easier.

    • @Apenschi
      @Apenschi Před 2 lety

      Yes, unless you need complex queries. Then you find out that it isn't easier and isn't faster!

    • @HeyFlutter
      @HeyFlutter  Před 2 lety

      Thank you, Thomas! 🙂

  • @elcanpenahov435
    @elcanpenahov435 Před 2 lety

    Can i use it for flutter web?

    • @antonyaz3506
      @antonyaz3506 Před 2 lety +1

      pub.dev object box.
      yes, you can

    • @HeyFlutter
      @HeyFlutter  Před 2 lety +2

      Thanks for your answer, Anton Yaz! 🙂

    • @Apenschi
      @Apenschi Před 2 lety

      @@antonyaz3506 ?!? There is no Flutter-Web compatibility?!?

  • @chandanvishwakarma8750

    please hive is good or object box

    • @antonyaz3506
      @antonyaz3506 Před 2 lety +1

      Hive for really simple tasks, object box for more complex tasks

    • @HeyFlutter
      @HeyFlutter  Před 2 lety

      Thank You Chandan Vishwakarma! Follow this link: objectbox.io/flutter-databases-sqflite-hive-objectbox-and-moor/
      I hope you will get your answer 🙂

  • @sfdsfdsgfgsfsgfsgfsgf2768

    Is objectBox free? Locally and remotely? This is so illogical, where do they make money then?

    • @HeyFlutter
      @HeyFlutter  Před rokem

      Thank You sfdsfdsgf gsfsgfsgfsgf! Follow this link: objectbox.io/
      I hope you will get your answer 🙂

    • @MadeInPython
      @MadeInPython Před 6 měsíci

      ObjectBox is not free if you want to synch your data

  • @commie563
    @commie563 Před rokem

    Is ObjectBox good for a complicated accounting software like QuickBooks or Sage.

    • @HeyFlutter
      @HeyFlutter  Před rokem

      Thank You Thahir Ahmed! Follow this link: medium.flutterdevs.com/objectbox-a-nosql-database-for-flutter-dart-4aac33870c41
      I hope you will get your answer 🙂

  • @abderrazakkenniche4995

    Hi, thanks alot
    Can you please make a video about using SQFLite on desktop for linux and Windows
    I think we must use sqfliteFFi but i could understand all well
    I hope u can help me

    • @HeyFlutter
      @HeyFlutter  Před 2 lety +1

      Thanks for the idea, AbdErrazak Kenniche! 🙂 I have added it to my list of ideas for future videos!

    • @abderrazakkenniche4995
      @abderrazakkenniche4995 Před 2 lety

      @@HeyFlutter thank you dude