Task #1951 (closed)
BUG: exception after a single row is added to a recreated table
Reported by: | bwzloranger | Owned by: | jamoore |
---|---|---|---|
Priority: | n.a. | Milestone: | OMERO-Beta4.2 |
Component: | n.a. | Version: | n.a. |
Keywords: | n.a. | Cc: | |
Resources: | n.a. | Referenced By: | n.a. |
References: | n.a. | Remaining Time: | 0.0d |
Sprint: | 2010-03-05 (4) |
Description
Creating a single 'row' of data in a new table will throw an exception once you try to read the data. For example:
// Creates a number of empty rows of [rows] size for the base history table private Column[] createBaseColumns(int rows) { Column[] newColumns = new Column[3]; newColumns[BASE_UID_COLUMN] = new LongColumn("Uid", "", new long[]{1}); newColumns[BASE_DATETIME_COLUMN] = new LongColumn("DateTime", "", new long[]{1}); newColumns[BASE_STATUS_COLUMN] = new StringColumn("Status", "", 100, new String[]{"c"}); return newColumns; }
will throw an error when trying to do:
public Data getBaseTableData() throws ServerError { long rows = baseTable.getNumberOfRows(); System.err.println("Number of rows in base Table: " + rows); long[] ColNumbers = {BASE_UID_COLUMN, BASE_DATETIME_COLUMN, BASE_STATUS_COLUMN}; Data d = baseTable.read(ColNumbers, 0L, rows); return d; }
Sample test file included illustrates this problem.
Attachments (1)
Change History (6)
Changed 14 years ago by bwzloranger
comment:1 Changed 14 years ago by jmoore
- Remaining Time set to 0.25
- Status changed from new to assigned
comment:2 Changed 14 years ago by jmoore
- Remaining Time changed from 0.25 to 0
- Resolution set to fixed
- Status changed from assigned to closed
comment:3 Changed 14 years ago by jmoore
comment:4 Changed 13 years ago by jmoore <josh@…>
(In [841f8e4ea13cd7a766991be568927beaf0902157/ome.git] on branch dev_4_1_custom) fix #1951 - another workaround for fromrows
git-svn-id: file:///home/svn/omero/trunk@6226 05709c45-44f0-0310-885b-81a1db45b4a6
comment:5 Changed 13 years ago by jmoore <josh@…>
(In [b82e2a017c2dd1f06f462eaae35b9acbbcbac3a7/ome.git] on branch dev_4_1_custom) fix #2159 - Moving to tolist() for all column types (see #1951, #2160)
git-svn-id: file:///home/svn/omero/trunk@6596 05709c45-44f0-0310-885b-81a1db45b4a6
(In [6226]) fix #1951 - another workaround for fromrows