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. Fail to connect to Oracle database sometimes

Fail to connect to Oracle database sometimes

Scheduled Pinned Locked Moved Unsolved General and Desktop
5 Posts 2 Posters 1.4k 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.
  • NuffN Offline
    NuffN Offline
    Nuff
    wrote on last edited by
    #1

    I'm having an issue connecting to the Oracle database. Some schemas can connect programmatically using QSqlDatabase::open() while other schemas fail to connect programmatically. The schemas that fail to connect programmatically using QSqlDatabase::open() can make the connection via sqlplus and sqldeveloper without any problem.

    I have tried using QSqlError:databaseText() and QSqldatabase::driverText and both methods fail to elaborate on what the connection issue is.

    Any ideas?

    1 Reply Last reply
    0
    • NuffN Offline
      NuffN Offline
      Nuff
      wrote on last edited by
      #2

      Sorry I meant to say

      I have tried using QSqlError::databaseText() and QSqlError::driverText() and both methods fail to elaborate on what the connection issue is

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

        Hi and welcome to devnet,

        Can you explain the difference between the working and non-working databases ?

        Also, which version of Qt are you using ? On what OS ?

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

        NuffN 1 Reply Last reply
        0
        • SGaistS SGaist

          Hi and welcome to devnet,

          Can you explain the difference between the working and non-working databases ?

          Also, which version of Qt are you using ? On what OS ?

          NuffN Offline
          NuffN Offline
          Nuff
          wrote on last edited by
          #4

          @SGaist
          I am using Qt 4.7
          I am confused by your use of the word database in the Oracle world. In Oracle each user/logon is represented as a schema. These schemas which I am using are imported into my local oracle database from an external oracle database using the Oracle impdp tool. As I mentioned some of the newly imported schemas work just fine with QT connecting to the database. Other imports work with the Orlacle interfaces sqlplus and sqldeveloper allowing me to connect to the database but fail to make the connection with the QSqlDatabase:::open() method.

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

            Qt 4.7 is pretty outdated, you should switch to Qt 5 or if you can't you should at least go with 4.8.7 which is the latest and last release of the Qt 4 series.

            Can you describe precisely what the difference is between your working and not working use case ?

            How are you trying to establish the connections ?

            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