Apache OpenOffice (AOO) Bugzilla – Full Text Issue Listing |
Summary: | Base query wizard error due to missing quoting of table and column names | ||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Product: | Base | Reporter: | antonio1 <win22> | ||||||||||||||||
Component: | code | Assignee: | AOO issues mailing list <issues> | ||||||||||||||||
Status: | RESOLVED FIXED | QA Contact: | |||||||||||||||||
Severity: | Major | ||||||||||||||||||
Priority: | P3 | CC: | damjan, oooforum | ||||||||||||||||
Version: | 4.0.0 | ||||||||||||||||||
Target Milestone: | 4.2.0 | ||||||||||||||||||
Hardware: | PC | ||||||||||||||||||
OS: | All | ||||||||||||||||||
Issue Type: | DEFECT | Latest Confirmation in: | 4.2.0-dev | ||||||||||||||||
Developer Difficulty: | --- | ||||||||||||||||||
Attachments: |
|
Description
antonio1
2015-01-12 15:44:47 UTC
Your bug report is being closed as NOT_AN_ISSUE due to a lack of information which is needed in order to accurately reproduce and confirm the problem. We encourage you to retest your bug against the latest release. If the issue is still present in the latest stable release, we need the following information: a) Provide a step-by-step procedure to reproduce (the simpler will be the better) b) Provide any test case(s) which will help us confirm the problem (like a sample document) c) Provide screenshots of the problem if you think it might help Once all of this is done, please set the bug back to UNCONFIRMED and we will attempt to reproduce the issue. Created attachment 84407 [details]
1
Created attachment 84408 [details]
2
Created attachment 84409 [details]
3
Created attachment 84410 [details]
2a
Created attachment 84411 [details]
here the step by step query
here is making query by query wisard.
i set condition yy=2001 but in result this condition not settled on 2a picture. on 3 pic. see - result all records are choose, not 2001 only.
Created attachment 84412 [details]
sql query
direct sql doesn't accepted conditions
i just find, that this bug was when only one conditions choosed. when 2 conditions choosed, the query created. is it bug or special feature? Please read more attentively my comment 1. Screenshots are fine but an ODB is better to reproduce. Save our time and provide informations required. of coarce,sir, i can send odb, but to your private mail, because it has some pers data,i'm in doubt to expose it public. This is a public bug tracking system, so if you attach a file, it does not contain confidential data. See this tutorial: https://forum.openoffice.org/en/forum/viewtopic.php?f=74&t=8289 to know how do it. Created attachment 84413 [details]
syntax errors
base even truncated is 1.3 mb(20 records)
is it bug or normal
Confirming even with latest SVN. Open the database in comment 13. Queries -> Use Wizard to Create Query, choose table 589, in step 3 "Search conditions" choose "yy" "is equal to" "2001", click "Next" right up until the end. The query is created without that condition. When a second condition is entered, both conditions work correctly. The following exception is logged on the console when "Next" is clicked: Nov 07, 2015 8:26:30 AM com.sun.star.wizards.ui.FilterComponent getFilterConditions SEVERE: null com.sun.star.sdbc.SQLException: Syntax error in SQL expression java stack trace: at com.sun.star.bridges.jni_uno.JNI_proxy.dispatch_call(Native Method) at com.sun.star.bridges.jni_uno.JNI_proxy.invoke(JNI_proxy.java:171) at com.sun.proxy.$Proxy59.setElementaryQuery(Unknown Source) at com.sun.star.wizards.ui.FilterComponent.getFilterConditions(FilterComponent.java:256) at com.sun.star.wizards.query.QueryWizard.leaveStep(QueryWizard.java:341) at com.sun.star.wizards.ui.WizardDialog.switchToStep(WizardDialog.java:359) at com.sun.star.wizards.ui.WizardDialog.gotoNextAvailableStep(WizardDialog.java:677) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:497) at com.sun.star.wizards.ui.event.MethodInvocation.invoke(MethodInvocation.java:90) at com.sun.star.wizards.ui.event.AbstractListener.invoke(AbstractListener.java:86) at com.sun.star.wizards.ui.event.CommonListener.actionPerformed(CommonListener.java:45) at com.sun.star.bridges.jni_uno.JNI_proxy.dispatch_call(Native Method) at com.sun.star.bridges.jni_uno.JNI_proxy.invoke(JNI_proxy.java:171) at com.sun.proxy.$Proxy57.execute(Unknown Source) at com.sun.star.wizards.ui.UnoDialog.executeDialog(UnoDialog.java:730) at com.sun.star.wizards.query.QueryWizard.start(QueryWizard.java:127) at com.sun.star.wizards.query.CallQueryWizard$QueryWizardImplementation.trigger(CallQueryWizard.java:92) at com.sun.star.bridges.jni_uno.JNI_proxy.dispatch_call(Native Method) at com.sun.star.bridges.jni_uno.JNI_proxy.invoke(JNI_proxy.java:171) at com.sun.proxy.$Proxy59.setElementaryQuery(Unknown Source) at com.sun.star.wizards.ui.FilterComponent.getFilterConditions(FilterComponent.java:256) at com.sun.star.wizards.query.QueryWizard.leaveStep(QueryWizard.java:341) at com.sun.star.wizards.ui.WizardDialog.switchToStep(WizardDialog.java:359) at com.sun.star.wizards.ui.WizardDialog.gotoNextAvailableStep(WizardDialog.java:677) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:497) at com.sun.star.wizards.ui.event.MethodInvocation.invoke(MethodInvocation.java:90) at com.sun.star.wizards.ui.event.AbstractListener.invoke(AbstractListener.java:86) at com.sun.star.wizards.ui.event.CommonListener.actionPerformed(CommonListener.java:45) at com.sun.star.bridges.jni_uno.JNI_proxy.dispatch_call(Native Method) at com.sun.star.bridges.jni_uno.JNI_proxy.invoke(JNI_proxy.java:171) at com.sun.proxy.$Proxy57.execute(Unknown Source) at com.sun.star.wizards.ui.UnoDialog.executeDialog(UnoDialog.java:730) at com.sun.star.wizards.query.QueryWizard.start(QueryWizard.java:127) at com.sun.star.wizards.query.CallQueryWizard$QueryWizardImplementation.trigger(CallQueryWizard.java:92) #i126029# Base query wizard error due to missing quoting of table and column names During the Base query design wizard, com.sun.star.wizards.ui.FilterComponent.getFilterConditions() calls com.sun.star.wizards.db.SQLQueryComposer.getSelectClause() before its getFromClause(). However the getSelectClause() needs composedCommandNames which is populated only by getFromClause() in order to quote table and column names. Without this, table and column names that need quoting (spaces, special characters, reserved words) produce errors. The syntax error is on the user's side: missing space before "and" and table name not quoted. As for the serious problem here, where table and column name were not getting quoted, leading to an error creating the query, patch was committed in revision 1713164: #i126029# Base query wizard error due to missing quoting of table and column names During the Base query design wizard, com.sun.star.wizards.ui.FilterComponent.getFilterConditions() calls com.sun.star.wizards.db.SQLQueryComposer.getSelectClause() before its getFromClause(). However the getSelectClause() needs composedCommandNames which is populated only by getFromClause() in order to quote table and column names. Without this, table and column names that need quoting (spaces, special characters, reserved words) produce errors. Resolving fixed. |