Uploaded image for project: 'i2b2 Core Software'
  1. i2b2 Core Software
  2. CORE-228

Exception when running parallel queries using Postgres

    XMLWordPrintable

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 1.7.06, 1.7.07
    • 1.7.09
    • CRC Cell
    • None
    • Rank:
      0|i0031r:
    • Queries
    • i2b2 Core
    • PostgreSQL

    Description

      This issue was reported by Robert Lodahl from the University Medical Center Gottingen.

      When running multiple parallel queries requesting a PDO, the CRC will return an error. It appears, for all parallel queries run by the custom plugin, the same connection is used.

      Upon further investigation, Robert has located the problem to the local temporary tables (like #temp_fact_param_table in this case) are only local for every connection, not per statement. So the first query starts, creating the table, wanting to execute something using this table, while the second query starts and drops the table (marked in bold). Obviously an exception occurs because the table no longer exists.

      The ERROR message that appears is:
       
      "Caused by: org.postgresql.util.PSQLException: ERROR: relation "temp_fact_param_table" does not exist“
       

      The exception can be traced back to the part of the code:

      edu.harvard.i2b2.crc.dao.pdo.PdoQueryConceptDao.getConceptByFact(PdoQueryConceptDao.java:346)
       

      The section of code that appears to be causing the problem can be seen in the attached document.

      ATTACHMENTS:

      EMAIL_Parallel_Queries_Error.pdf = original email from Robert.

      Attachments

        Activity

          People

            jmd86 Janice Donahoe
            jmd86 Janice Donahoe
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: