Issue 96703

Summary: Form-subform relation fails with direct SQL
Product: Base Reporter: villeroy <villeroy>
Component: codeAssignee: AOO issues mailing list <issues>
Status: UNCONFIRMED --- QA Contact:
Severity: Trivial    
Priority: P3 CC: issues
Version: OOo 1.0.0   
Target Milestone: ---   
Hardware: Unknown   
OS: All   
Issue Type: DEFECT Latest Confirmation in: ---
Developer Difficulty: ---
Description Flags
Form and subform bound to queries. none

Description villeroy 2008-11-29 08:27:36 UTC
Load any form with a subform and change the source type of either one to some
unparsed SQL query. For instance, change (sub-) form's source from "TableX" to
direct SQL SELECT * FROM "TableX". The subform won't follow the main form anymore.
Comment 1 leggewie 2008-11-29 17:40:41 UTC
Maybe you can attach a test case?
Comment 2 villeroy 2008-11-29 19:21:32 UTC
Open the form of the attached database.
Jump from item to item and watch the subform showing the category of the
selected item. Close the form.
Open any of the queries in SQL view and turn on direct SQL mode (Edit menu).
Store the query and open the form again. The categories are not bound to the
items anymore.
Comment 3 villeroy 2008-11-29 19:24:01 UTC
Created attachment 58393 [details]
Form and subform bound to queries.
Comment 4 eremmel 2009-03-15 23:50:13 UTC
A workaround is to implement the Direct-SQL query as an view and use the view in
the sub-form. This is however limited to read-only form-subform relations.
Comment 5 villeroy 2009-03-16 00:02:19 UTC
Thanks for the work-around. Direct SQL-queries are read-only too. So this
limitation does not make any difference. But why is almost every row set
read-only in this database tool? 
Comment 6 bobban 2009-10-06 15:35:20 UTC
Just want to confirm that I have also been burnt by this bug. Any use of Direct
Mode SQL queryies in a linked form breaks the linkage. However a form based
solely on this query is ok. A thread which details my own experience with
discovering this bug here