Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Qt with Realm-CPP DB. How?
Forum Update on Tuesday, May 27th 2025

Qt with Realm-CPP DB. How?

Scheduled Pinned Locked Moved Unsolved General and Desktop
7 Posts 3 Posters 276 Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • B Offline
    B Offline
    bogong
    wrote on 9 Jan 2025, 18:05 last edited by bogong 1 Sept 2025, 18:40
    #1

    Hello all!

    Does anybody know something of how to use Realm-CPP with Qt 6/5 application? Is there any examples of implementing Realm in Qt project?

    1 Reply Last reply
    0
    • C Offline
      C Offline
      Christian Ehrlicher
      Lifetime Qt Champion
      wrote on 9 Jan 2025, 19:14 last edited by
      #2

      What do you want to implement? Compile the library and then use FIND_PACKAGE(cpprealm) to search for the package. If found link it to your app with target_link_libraries(MyApp PUBLIC cpprealm::cpprealm).
      This should be added to the cpprealm README though - you should ask them to add this information on how to use the library with cmake.

      Qt Online Installer direct download: https://download.qt.io/official_releases/online_installers/
      Visit the Qt Academy at https://academy.qt.io/catalog

      1 Reply Last reply
      1
      • B Offline
        B Offline
        bogong
        wrote on 10 Jan 2025, 07:56 last edited by bogong 1 Oct 2025, 07:58
        #3

        Mostly trying to find examples of using Realm DB written with CPP. Library itself built for all of platforms (iOS/Android/MacOS) like static library, there are sh scripts in repository. But how to use it isn't clear. Means example that showing manipulations with data in DB and DB itself. It's very different to SQL DBs.

        1 Reply Last reply
        0
        • C Offline
          C Offline
          Christian Ehrlicher
          Lifetime Qt Champion
          wrote on 10 Jan 2025, 08:21 last edited by
          #4

          So you should ask the authors on how to use their library, or?

          Qt Online Installer direct download: https://download.qt.io/official_releases/online_installers/
          Visit the Qt Academy at https://academy.qt.io/catalog

          1 Reply Last reply
          1
          • B Offline
            B Offline
            bogong
            wrote on 10 Jan 2025, 14:56 last edited by
            #5

            There were hope on someone who already did it with Qt ...

            1 Reply Last reply
            0
            • C Offline
              C Offline
              Christian Ehrlicher
              Lifetime Qt Champion
              wrote on 10 Jan 2025, 14:59 last edited by
              #6

              tbh. I don't see what's so special using an external c++ library with Qt or any other framework/application. So search for normal c++ examples for your library.

              Qt Online Installer direct download: https://download.qt.io/official_releases/online_installers/
              Visit the Qt Academy at https://academy.qt.io/catalog

              1 Reply Last reply
              0
              • J Offline
                J Offline
                JonB
                wrote on 10 Jan 2025, 15:13 last edited by
                #7

                From my limited understanding and reading

                • Realm-CPP is just C++ code and you can integrate/call it like anything else C++ from Qt.
                • BUT Realm-CPP DB --- as written in your title but not in your question --- is some kind of database which is supposed to be "like SQLite".

                If it is the DB/database side you want to use then if you want it to work with Qt QSql... classes you will have to use or produce a driver for it, like QSQLITE or QMYSQL. If you only wish to make explicit calls to whatever its C++ interface is, not via QSql.... classes, then you can do that as plain C++ code.

                1 Reply Last reply
                0

                1/7

                9 Jan 2025, 18:05

                • Login

                • Login or register to search.
                1 out of 7
                • First post
                  1/7
                  Last post
                0
                • Categories
                • Recent
                • Tags
                • Popular
                • Users
                • Groups
                • Search
                • Get Qt Extensions
                • Unsolved