Re: V7.0 Rowid ...
Posted in 1995
At 12:27 PM 7/14/95, Bob Baskett wrote:
>jon,
>> ROWIDS do exist in version 7.x However:
>> - If you fragment a table, ROWIDS are no longer unique within the table
>> (i.e. each fragment is essentially a table, and has its own ROWID set).
>
>have you actually tested this? in our testing, we found rowid to be unique
>across the table, not just fragments...
You only get uniqueness, if table is created "with rowids", in which case an
implicit column "rowid" is added to the table. Try selecting rowid on a
fragmented table created without "with rowids".
>> - If you do NOT fragment a table, then ROWID exists as it did before.
>> However, Informix has continually stated that this may change. Save yourself
>> some time and grief, and start thinking about removing ROWID from
>> applications, and move toward primary keys.
>> - If a table is fragmented, you can create or alter the table to create a
>> rowid column (RTFM ver7 syntax for create/alter table).This was put in,
>> because so many people were using them. When you do this though, you
>> essentially add a new serial column to the table, and it becomes indexed. At
>> this point, it behaves just as any other indexed column, and carries the
>> associated overhead of such. So, again this is another reason to use primary
>> keys, you reduce the schema by 4 bytes, plus the index overhead.
>>
>not exactly, try creating a fragmented table with rowids then doing a
>oncheck -pe.
In looking at the oncheck -pe output, it appears as though the rowid column
is maintained in some kind of seperate table. I had not noticed this before.
I do know, however, that when you fragment, and include "with rowids" a
serial column is somehow attached to the table. This serial column is
indexed, so you inherit all the associated overhead. (according to Informix R&D)
Jon
==================================================================
Jon Vemo Internet: jvemo@cyberspace.com
Bothell, WA USA
------------------------------------------------------------------
Watch out for road-kill on the information superhighway....SPLAT!!
==================================================================