[Libreoffice-bugs] [Bug 108105] New: Multiple errors in Postgresql log when using subforms

bugzilla-daemon at bugs.documentfoundation.org bugzilla-daemon at bugs.documentfoundation.org
Fri May 26 09:07:10 UTC 2017


https://bugs.documentfoundation.org/show_bug.cgi?id=108105

            Bug ID: 108105
           Summary: Multiple errors in Postgresql log when using subforms
           Product: LibreOffice
           Version: 5.3.3.2 release
          Hardware: All
                OS: All
            Status: UNCONFIRMED
          Severity: normal
          Priority: medium
         Component: Base
          Assignee: libreoffice-bugs at lists.freedesktop.org
          Reporter: work at sorha-consulting.be

Description:
 I'm using a database connected to PostgreSQL 9.6. there are some simple forms
and others more complex (5 levels of subforms).

When loading subform including at least one subform, many error messages are
generated by PostgreSQL:

STATEMENT: SELECT * FROM "public"."logement" WHERE ( 0 = 1 ) AND ( ( (
"public"."logement"."id" = :link_from_id_logement ) ) AND ( 0 = 1 ) ) ERROR:
syntax error at or near ":" at character 88 STATEMENT: SELECT * FROM
"public"."immeuble" WHERE ( 0 = 1 ) AND ( ( ( "public"."immeuble"."id" =
:link_from_immeuble ) ) AND ( 0 = 1 ) ) ERROR: syntax error at or near ":" at
character 82 STATEMENT: SELECT * FROM "public"."ville" WHERE ( 0 = 1 ) AND ( (
( "public"."ville"."id" = :link_from_adresse_ville ) ) AND ( 0 = 1 ) ) ERROR:
syntax error at or near ":" at character 94 *STATEMENT: SELECT * FROM
"public"."code_postal" WHERE ( 0 = 1 ) AND ( ( ( "public"."code_postal"."id" =
:link_from_adresse_cp ) ) AND ( 0 = 1 ) ) ERROR: syntax error at or near ":" at
character 78 STATEMENT: SELECT * FROM "public"."rue" WHERE ( 0 = 1 ) AND ( ( (
"public"."rue"."id" = :link_from_adresse_rue ) ) AND ( 0 = 1 ) ) ERROR: syntax
error at or near ":" at character 96 STATEMENT: SELECT * FROM
"public"."l_zone_rue" WHERE ( 0 = 1 ) AND ( ( ( "public"."l_zone_rue"."id_rue"
= :link_from_adresse_rue ) AND ( "public"."l_zone_rue"."numero_rue_de" =
:link_from_numero_rue ) ) AND ( 0 = 1 ) ) ERROR: syntax error at or near ":" at
character 82 STATEMENT: SELECT * FROM "public"."zones" WHERE ( 0 = 1 ) AND ( (
( "public"."zones"."id" = :link_from_id_zone ) ) AND ( 0 = 1 ) ) ERROR: syntax
error at or near ":" at character 92 STATEMENT: SELECT * FROM
"public"."l_cq_rue" WHERE ( 0 = 1 ) AND ( ( ( "public"."l_cq_rue"."id_rue" =
:link_from_adresse_rue ) AND ( "public"."l_cq_rue"."numero_rue_de" =
:link_from_numero_rue ) ) AND ( 0 = 1 ) ) ERROR: syntax error at or near ":" at
character 104 STATEMENT: SELECT * FROM "public"."contrat_quartier" WHERE ( 0 =
1 ) AND ( ( ( "public"."contrat_quartier"."id" = :link_from_id_cq ) ) AND ( 0 =
1 ) ) ERROR: syntax error at or near ":" at character 84 STATEMENT: SELECT *
FROM "public"."usager" WHERE ( 0 = 1 ) AND ( ( ( "public"."usager"."id" =
:link_from_id_proprietaire ) ) AND ( 0 = 1 ) ) ERROR: syntax error at or near
":" at character 84 STATEMENT: SELECT * FROM "public"."usager" WHERE ( 0 = 1 )
AND ( ( ( "public"."usager"."id" = :link_from_id_usager ) ) AND ( 0 = 1 ) )**

Forms are working correctly but loading is very slow, probably due to those
errors.

Connectors SDBC et JDBC give same result Have tried with Mac & Linux Ubuntu
16.04 version --> same result

Steps to Reproduce:
1.Create an ODB file connected to a PostgreSQL database 
2.Create a form including at least one subform (and some fields, of course). 
Subform must be connected to mai form via master-slave fields.
3.Load the form and check the PostgreSQL log

Actual Results:  
SQL errors, such as:
SELECT * FROM "public"."logement" WHERE ( 0 = 1 ) AND ( ( (
"public"."logement"."id" = :link_from_id_logement ) ) AND ( 0 = 1 ) ) ERROR:
syntax error at or near ":" at character 88


Expected Results:
No SQL errors, loading faster


Reproducible: Always

User Profile Reset: Yes

Additional Info:
JDBC & SDBC connectors have been tried --> same result
Tested on Mac OS 10.12 & Ubuntu 16.04

When setting "Analyse SQL command" parameter (subform details, DATA tab) to
"NO", Libreoffice displays a pop-up message mentionning 

"Error code 1
The data content could not be loaded.
pq_preparedstatement: parameter index out of range (expected 1 to 0, got 1,
statement 'SELECT * FROM "PUBLIC"."SUBFORM_TABLE_NAME"'

and loading is stopped.


When setting "Analyse SQL command" parameter (subform details, DATA tab) to
"YES", loading is OK but errors are logged by PostgreSQL



User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_5) AppleWebKit/537.36
(KHTML, like Gecko) Chrome/58.0.3029.110 Safari/537.36

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/libreoffice-bugs/attachments/20170526/d86ab2d6/attachment.html>


More information about the Libreoffice-bugs mailing list