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. ActiveRecord in Qt
Qt 6.11 is out! See what's new in the release blog

ActiveRecord in Qt

Scheduled Pinned Locked Moved General and Desktop
25 Posts 6 Posters 19.0k Views 1 Watching
  • 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.
  • I Offline
    I Offline
    ivan.todorovich
    wrote on last edited by
    #1

    Hi,

    I wonder if someone has created a library that uses ActiveRecord's pattern in Qt.

    o_o Sorry for my rusted english.

    1 Reply Last reply
    0
    • G Offline
      G Offline
      goetz
      wrote on last edited by
      #2

      We have created a similar approach in one of our projects. Instead of saving in a database directly, we use some hand-crafted XML to push the data to java based server application that does the actual db operations.

      Unfortunately I cannot post source code, as this is a closed source project.

      To be flexible, one might consider adding a wrapper level between the objects and the database or provide a kind of database driver for getting and submitting the data to a remote server.

      http://www.catb.org/~esr/faqs/smart-questions.html

      1 Reply Last reply
      0
      • G Offline
        G Offline
        goetz
        wrote on last edited by
        #3

        For those who are not familiar with the concept: A short "descripton of ActiveRecord on wikipedia":http://en.wikipedia.org/wiki/Active_record_pattern.

        http://www.catb.org/~esr/faqs/smart-questions.html

        1 Reply Last reply
        0
        • D Offline
          D Offline
          DenisKormalev
          wrote on last edited by
          #4

          Heard about couple of qt projects that provides orm functionality. I will find them and post back

          1 Reply Last reply
          0
          • I Offline
            I Offline
            ivan.todorovich
            wrote on last edited by
            #5

            Hey, thanks. That would really help me.
            I was thinking in making an ActiveRecord library of my own, just to satisfy the needs of my project.
            But I just thought that would be better to adapt an existing project, don't you think?
            Anyway any help and examples would be appreciated.

            I really like the "Ruby ActiveRecord's API":http://ar.rubyonrails.org/.
            Thanks,
            Iván

            o_o Sorry for my rusted english.

            1 Reply Last reply
            0
            • A Offline
              A Offline
              andre
              wrote on last edited by
              #6

              I have a concept mail to the qt mailinglist hanging around with thoughts about this issue. I really think something like this is needed, but it needs to be Done Right (TM). ORM frameworks for Qt that I know of are QDjango, QsT SQL Tools, QxOrm and QtPersistence. None of these seem to fit my bill, but there are interesting ideas in some of them.

              1 Reply Last reply
              0
              • D Offline
                D Offline
                DenisKormalev
                wrote on last edited by
                #7

                Yes, I've meant QDjango, QxOrm and QsT. As I know last one was made to avoid problems in other ORMs for Qt, so maybe it will become awesome tool someday.

                1 Reply Last reply
                0
                • B Offline
                  B Offline
                  blex
                  wrote on last edited by
                  #8

                  [quote author="Denis Kormalev" date="1291220985"]Heard about couple of qt projects that provides orm functionality. I will find them and post back[/quote]

                  http://opensource.bolloretelecom.eu/projects/qdjango/

                  But I do not know anything about it's quality.


                  Oleksiy Balabay

                  1 Reply Last reply
                  0
                  • D Offline
                    D Offline
                    DenisKormalev
                    wrote on last edited by
                    #9

                    blex, at the September QDjango had too little features. But all other ORMs are also not fully-featured. AFAIK QxOrm is the most featured library now.

                    1 Reply Last reply
                    0
                    • B Offline
                      B Offline
                      blex
                      wrote on last edited by
                      #10

                      [quote author="Denis Kormalev" date="1291285604"]blex, at the September QDjango had too little features. But all other ORMs are also not fully-featured. AFAIK QxOrm is the most featured library now.[/quote]

                      Thank you for information.

                      But my opinion is that C++ is not a good choice for ORM. ORM lives better in Java and Net :)


                      Oleksiy Balabay

                      1 Reply Last reply
                      0
                      • A Offline
                        A Offline
                        andre
                        wrote on last edited by
                        #11

                        [quote author="blex" date="1291285797"]
                        But my opinion is that C++ is not a good choice for ORM. ORM lives better in Java and Net :) [/quote]

                        IMHO, you don't choose a language just for building an ORM. You use an ORM as part of your application for which you have chosen a language. If you choose Qt, then you have already chosen C++ in most cases.

                        Back to the issue in question: an ORM for Qt.
                        Dennis: what specific issues was QsT SQL Tools designed to avoid?

                        1 Reply Last reply
                        0
                        • D Offline
                          D Offline
                          DenisKormalev
                          wrote on last edited by
                          #12

                          Andre, I didn't use it, but I've read QsT maintaners article about it. He said that it was designed to make library users live easier. Also he said that it is not an ORM in common, it is something that is near to ORM. There are some problems witch caching, relations support (QxOrm will be the best in this case), full sql support.

                          1 Reply Last reply
                          0
                          • A Offline
                            A Offline
                            andre
                            wrote on last edited by
                            #13

                            I just downloaded it, and I immediately noticed one massive drawback for me. All documentation is in Russian. That makes it impossible for me to work with it, I fear. Pitty.

                            1 Reply Last reply
                            0
                            • D Offline
                              D Offline
                              DenisKormalev
                              wrote on last edited by
                              #14

                              Andre, oops, didn't know it. If you want I can ask maintainer to write english docs.

                              1 Reply Last reply
                              0
                              • I Offline
                                I Offline
                                ivan.todorovich
                                wrote on last edited by
                                #15

                                [quote author="Andre" date="1291288904"]I just downloaded it, and I immediately noticed one massive drawback for me. All documentation is in Russian. That makes it impossible for me to work with it, I fear. Pitty. [/quote]
                                Same :(

                                BUT, QDjango looks really good. At least for my needs right now.. I will check it out later. Thanks

                                o_o Sorry for my rusted english.

                                1 Reply Last reply
                                0
                                • A Offline
                                  A Offline
                                  andre
                                  wrote on last edited by
                                  #16

                                  [quote author="Denis Kormalev" date="1291291416"]Andre, oops, didn't know it. If you want I can ask maintainer to write english docs.[/quote]
                                  Please do. In the meantime, I created a ticket for it on sourceforge with the same request as well. Even the in-code stuff is in Russian, though the method and class names are in English.

                                  1 Reply Last reply
                                  0
                                  • D Offline
                                    D Offline
                                    DenisKormalev
                                    wrote on last edited by
                                    #17

                                    Andre, done. Will update you when he will answer me.

                                    1 Reply Last reply
                                    0
                                    • D Offline
                                      D Offline
                                      DenisKormalev
                                      wrote on last edited by
                                      #18

                                      Andre, maintaner answered that he translation is in progress now. Full translation will be in approx 3 months (with 0.5 version of QsT).

                                      Here:
                                      @http://sourceforge.net/projects/qstsqltools/files/QST 0.5/doc_english_partial QST 0.5.6.zip/download@
                                      you can download partial translation of docs.

                                      1 Reply Last reply
                                      0
                                      • G Offline
                                        G Offline
                                        graninas
                                        wrote on last edited by
                                        #19

                                        Good day to all!

                                        Andre, documentation of the QsT SQL Tools is fully translated to English. If you are still interested, you can get it "here":https://sourceforge.net/projects/qstsqltools/files/QST 0.5/QST 0.5.9.4 beta/ with the sources.

                                        With best regards.

                                        1 Reply Last reply
                                        0
                                        • A Offline
                                          A Offline
                                          andre
                                          wrote on last edited by
                                          #20

                                          Great! Thank you for the follow-up. I am always interested in looking into interesting libraries like this.

                                          1 Reply Last reply
                                          0

                                          • Login

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