Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Mobile and Embedded
  4. MySql Database Connection, mingw yes, android no
Forum Updated to NodeBB v4.3 + New Features

MySql Database Connection, mingw yes, android no

Scheduled Pinned Locked Moved Unsolved Mobile and Embedded
androidsql
4 Posts 2 Posters 1.8k Views 2 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.
  • M Offline
    M Offline
    mr__710
    wrote on last edited by
    #1

    Hello everybody,
    i wrote a program to connect to a database (made with xampp mysql) and read some values from it. I got the connection with mingw to my localhost (127.0.0.1), but when i want to compile with armeabi-v7 and my android device i get errors:

    W/libApp.so(21457): (null):0 ((null)): QSqlDatabase: QMYSQL driver not loaded
    W/libApp.so(21457): (null):0 ((null)): QSqlDatabase: available drivers: QSQLITE
    D/libApp.so(21457): (null):0 ((null)): "Driver not loaded Driver not loaded"

    What do i have to do?

    I read the article: Build Qt 5 MySQL Plugin for Android, but did not really understand it

    1 Reply Last reply
    0
    • SGaistS Offline
      SGaistS Offline
      SGaist
      Lifetime Qt Champion
      wrote on last edited by
      #2

      Hi,

      As silly as it may sound: follow the wiki article to build the driver. There's no official MySQL client library for Android but this article explains how to build the MariaDB client library for Android so your can build Qt's MySQL driver.

      Note that accessing a database connected directly through internet is a Bad Idea (™). Depending on your needs, a web service providing the info you are needing will be better.

      Interested in AI ? www.idiap.ch
      Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

      1 Reply Last reply
      0
      • M Offline
        M Offline
        mr__710
        wrote on last edited by
        #3

        ok, but i think it is only written for linux.

        Is there an alternative for connecting a database from the internet to an android device?
        I only need to read out the data (Datetime and Value)

        1 Reply Last reply
        0
        • SGaistS Offline
          SGaistS Offline
          SGaist
          Lifetime Qt Champion
          wrote on last edited by
          #4

          Use a web service for that, there are several frameworks that makes it pretty easy.

          Interested in AI ? www.idiap.ch
          Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

          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