Bug report #16001

Categorized renderer on a layer based on a postgis view calling foreign data from oracle (wrapper)

Added by Emma AEAG about 8 years ago. Updated over 7 years ago.

Status:Closed
Priority:Normal
Assignee:-
Category:Unknown
Affected QGIS version:2.14.9 Regression?:No
Operating System: Easy fix?:No
Pull Request or Patch supplied:No Resolution:up/downstream
Crashes QGIS or corrupts data:No Copied to github as #:23917

Description

Working with Qgis version 2.14.9/2.14.10, Windows 64

When unchecking one symbol item of a categorized layer or deleting the null category in the Style menu of the Layers Properties : all symbols are hidden. The layer I want to categorized comes from a postgis view that access foreign data in Oracle DB. That was OK in Qgis 2.12.1
This bug is quiet similar to #14273 that was fixed. But it (re)appears in Qgis 2.14.9 (idem with 2.14.10) with foreign postgis data.
Error report is :

2016-12-21T14:36:45    1    Recherche à partir du curseur qgis_3 a échoué
            Erreur dans la base de données : ERREUR:  error executing query: OCIStmtExecute failed to execute remote query
            DETAIL:  ORA-00938: nombre d'arguments insuffisant pour la fonction
2016-12-21T14:36:45    1    Requête : CLOSE qgis_3 a retourné 7 [ERREUR:  la transaction est annulée, les commandes sont ignorées jusqu'à la fin du bloc
            de la transaction
            ]
2016-12-21T14:36:45    1    1 cursor states lost.
            SQL: CLOSE qgis_3
            Résultat: 7 (ERREUR:  la transaction est annulée, les commandes sont ignorées jusqu'à la fin du bloc
            de la transaction
            )

History

#1 Updated by Jürgen Fischer about 8 years ago

  • Status changed from Open to Feedback

#2 Updated by Jürgen Fischer about 8 years ago

  • Status changed from Feedback to Open

#3 Updated by Nyall Dawson about 8 years ago

  • Priority changed from Severe/Regression to Normal

Decreasing severity due to the very rare set of conditions which lead to the bug.

#4 Updated by Nyall Dawson about 8 years ago

  • Status changed from Open to Closed
  • Resolution set to up/downstream

Actually on further thoughts I don't believe this is a QGIS bug at all and rather a bug in either Postgres, Oracle or the FDW. The queries QGIS uses for the categorised renderer are just standard SQL 'SELECT ... WHERE field IN ('some val','some other val',...)' format, and work correctly on Postgres databases. You'd need to try logging the queries QGIS sends and then isolate the query which fails using the wrapper and then report it upstream.

#5 Updated by Emma AEAG almost 8 years ago

Just for information :
You're right : the bug came from the request to create the view based on foreign table, that we want to load in Qgis.
Qgis 2.14 send a different request (optimized) for categorized layer than Qgis 2.12 : the "non correct" request that worked with Qgis 2.12 doesn't work with Qgis 2.14 anymore.

#6 Updated by Jürgen Fischer over 7 years ago

  • Category set to Unknown

Also available in: Atom PDF