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. Deployed QT app will not connect to Mysql on a certain Windows computer but will on others.
Forum Updated to NodeBB v4.3 + New Features

Deployed QT app will not connect to Mysql on a certain Windows computer but will on others.

Scheduled Pinned Locked Moved Solved General and Desktop
9 Posts 3 Posters 694 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.
  • J Offline
    J Offline
    JSher
    wrote on 30 Apr 2020, 20:02 last edited by
    #1

    Hello,

    I have a QT app that connects to a mysql database. I have it working fine on MOST windows computer but one of the main people I built it for, it does not work on that Windows 10 machine. I have tested it on 2 other windows 10 machines and it works fine on them as well as the one it was developed on.

    The error is unable to load mysql driver. I understand there is tons of these questions out there but this one is different as it is one computer causing the issue.

    When I look at the QT_DEBUG_PLUGINS trace on the computer it loads qsqlited.dll,qsqlmysqld.dll,qsqlodbcd.dll,qsqlpsqld.dll then when it hits qsqlmysqld.dll it says it cannot locate it. It is in the same directory it is looking.

    The libmysql is in the root and I have tried moving it all through the directory structure as there is no explicit mention of trying to load it in the debug plugins trace.

    Any have any experience with an application connecting on some computers and not others that are the same OS?

    Thanks,
    --James

    J 1 Reply Last reply 30 Apr 2020, 20:07
    0
    • B Offline
      B Offline
      Bonnie
      wrote on 1 May 2020, 03:04 last edited by Bonnie 5 Apr 2020, 21:57
      #4

      If you're using libmysql from MySql 8.0, it needs VS2015 runtime and openssl 1.0 dlls in the PATH or with the application.
      Could that be the reason?

      1 Reply Last reply
      3
      • J JSher
        30 Apr 2020, 20:02

        Hello,

        I have a QT app that connects to a mysql database. I have it working fine on MOST windows computer but one of the main people I built it for, it does not work on that Windows 10 machine. I have tested it on 2 other windows 10 machines and it works fine on them as well as the one it was developed on.

        The error is unable to load mysql driver. I understand there is tons of these questions out there but this one is different as it is one computer causing the issue.

        When I look at the QT_DEBUG_PLUGINS trace on the computer it loads qsqlited.dll,qsqlmysqld.dll,qsqlodbcd.dll,qsqlpsqld.dll then when it hits qsqlmysqld.dll it says it cannot locate it. It is in the same directory it is looking.

        The libmysql is in the root and I have tried moving it all through the directory structure as there is no explicit mention of trying to load it in the debug plugins trace.

        Any have any experience with an application connecting on some computers and not others that are the same OS?

        Thanks,
        --James

        J Offline
        J Offline
        JonB
        wrote on 30 Apr 2020, 20:07 last edited by JonB
        #2

        @JSher
        I believe Windows may report it cannot "find" a DLL to load if a dependency is missing. You should test on bad machine as @SGaist wrote in other thread:

        One thing you can do is run Dependency Walker on these various machines to check is there's a difference with the dependencies of the MySQL dlls.

        Also you talk about

        when it hits qsqlmysqld.dll it says it cannot locate it
        The libmysql is in the root and I have tried moving it

        libmysql != qsqlmysqld.dll, so not sure what you are looking at.

        1 Reply Last reply
        0
        • J Offline
          J Offline
          JSher
          wrote on 30 Apr 2020, 22:34 last edited by
          #3

          Ive ran the dependency walker and cannot see anything amis.

          I say libmysql because my thought was that qsqlmysql may be crashing because it cannot find it....I have tried moving qsqlmysql around as well, nothing....

          1 Reply Last reply
          0
          • B Offline
            B Offline
            Bonnie
            wrote on 1 May 2020, 03:04 last edited by Bonnie 5 Apr 2020, 21:57
            #4

            If you're using libmysql from MySql 8.0, it needs VS2015 runtime and openssl 1.0 dlls in the PATH or with the application.
            Could that be the reason?

            1 Reply Last reply
            3
            • J Offline
              J Offline
              JSher
              wrote on 1 May 2020, 10:27 last edited by
              #5

              @Bonnie I am using 6.1, does this still apply? Ill have a look

              Thanks,
              --James

              J 1 Reply Last reply 1 May 2020, 10:55
              0
              • J JSher
                1 May 2020, 10:27

                @Bonnie I am using 6.1, does this still apply? Ill have a look

                Thanks,
                --James

                J Offline
                J Offline
                JonB
                wrote on 1 May 2020, 10:55 last edited by JonB 5 Jan 2020, 10:56
                #6

                @JSher
                6.1 what exactly? There is no MySQL 6.1 :)
                https://en.wikipedia.org/wiki/MySQL#Release_history

                1 Reply Last reply
                0
                • J Offline
                  J Offline
                  JSher
                  wrote on 1 May 2020, 11:05 last edited by
                  #7

                  @JonB Sorry mysql connector 6.1...One of the last ones to include a built libmysql.dll/lib

                  --James

                  B 1 Reply Last reply 1 May 2020, 11:30
                  1
                  • J JSher
                    1 May 2020, 11:05

                    @JonB Sorry mysql connector 6.1...One of the last ones to include a built libmysql.dll/lib

                    --James

                    B Offline
                    B Offline
                    Bonnie
                    wrote on 1 May 2020, 11:30 last edited by Bonnie 5 Jan 2020, 11:36
                    #8

                    @JSher connector/c 6.1.11, right? It will still need VS2015 runtime

                    1 Reply Last reply
                    2
                    • J Offline
                      J Offline
                      JSher
                      wrote on 1 May 2020, 12:55 last edited by
                      #9

                      @Bonnie Your solution worked with VS2015. Thanks!!
                      --James

                      1 Reply Last reply
                      0

                      9/9

                      1 May 2020, 12:55

                      • Login

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