Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 314057

Summary: Enable subclass of Table Data Editor to provide result column ordering
Product: [Tools] Data Tools Reporter: Brian Payton <bpayton>
Component: Table Data EditorAssignee: Brian Payton <bpayton>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: P3    
Version: 1.8   
Target Milestone: 1.8   
Hardware: PC   
OS: Windows XP   
Whiteboard:
Attachments:
Description Flags
Patch for plugins o.e.d.sqltools.data.core and o.e.d.sqltools.data.ui none

Description Brian Payton CLA 2010-05-24 00:46:40 EDT
The Table Data Editor UI classes currently assume that the edit columns and rows map to SELECT * FROM <tablename>.  The UI has code like this:
  editor.getTable().getColumns() 
That is, the UI classes work with the columns of the source table of the query defining the edit, rather than the result columns of the query defining the edit.  The Table Data Editor core actually maintains a field for the result columns, "resultColumns", so that assumption is not needed.  However, this field is not exposed in the API.

The result columns field needs to be exposed in the TableData2 interface, and the Table Data Editor UI classes need to use it when accessing the edit columns rather than getting the edit columns directly from the source table.
Comment 1 Brian Payton CLA 2010-05-24 00:54:51 EDT
Created attachment 169626 [details]
Patch for plugins o.e.d.sqltools.data.core and o.e.d.sqltools.data.ui
Comment 2 Brian Payton CLA 2010-05-25 03:25:34 EDT
Checked in change, tagged to v201005241300.