[PATCH] Change in core[libreoffice-3-6]: fdo#50800 populate composedCommandNames ASAP, not at call of...

Gerrit gerrit at gerrit.libreoffice.org
Thu Jul 12 14:49:38 PDT 2012


>From Lionel Elie Mamane <lionel at mamane.lu>:

Lionel Elie Mamane has uploaded a new change for review.

Change subject: fdo#50800 populate composedCommandNames ASAP, not at call of getFromClause
......................................................................

fdo#50800 populate composedCommandNames ASAP, not at call of getFromClause

In particular com/sun/star/wizards/ui/FilterComponent calls getSelectClause before calling getFromClause, and then all hell breaks loose: composedCommandNames is empty, thus cannot find the proper Alias column name, thus the column names in the select list were not properly escaped, ...
We have just made getFromClause quadratic instead of linear, but:
1) I do not think this would be a problem (small datastructures)
2) If it is, rather use a hashmap or something like that, wich will also make getSelectClause faster

Also make the fallback case of "unknown table" more robust: escape the table name (if any) and column name!

Change-Id: I474adc51fc6378d836bd5865d9eb9505983dcbc5
---
M wizards/com/sun/star/wizards/db/SQLQueryComposer.java
1 file changed, 24 insertions(+), 9 deletions(-)


  git pull ssh://gerrit.libreoffice.org:29418/core refs/changes/03/303/1
--
To view, visit https://gerrit.libreoffice.org/303
To unsubscribe, visit https://gerrit.libreoffice.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I474adc51fc6378d836bd5865d9eb9505983dcbc5
Gerrit-PatchSet: 1
Gerrit-Project: core
Gerrit-Branch: libreoffice-3-6
Gerrit-Owner: Lionel Elie Mamane <lionel at mamane.lu>



More information about the LibreOffice mailing list