Is there an easier way to tell if a table was built "with rowid"?
Posted in 2026
Topics: General Discussion
For various reasons, mainly the need to partition some tables, we will need to alter fragment .. with rowid for some tables. But to avoid redundancy (and maybe upsetting an existing pseudo-rowid) I need to determine which tables in a database already have "with rowid". I know from elsewhere that when a partitioned table is "with rowid" it has an index named "system-rowid". (That's a dash, not an underscore.), hence, this query works toward that goal: select tabname[1,20], partition[1,10], fragtype, --t.tabid, indexname[1,20] from sysfragments f, systables t where t.tabid = f.tabid and indexname like "%rowid" order by tabname, partition ; But I was hoping for a simpler, more direct query, like a flag in systables on systabinfo. I will be posting a separate question of "with rowid", hopefully to remain theoretical. Ideas, anyone? ------------------------------ +-----------------------------------------------------------+ | I am pleased to report that I had no problems today. | | I had only issues, opportunities, challenges and valuable | | learning experiences. | +------------------------------------------ Jacob S --------+ ------------------------------
Running the following against systables will tell you if the table has been created with rowids:
select tabname
from systables
where sysmaster:bitval(flags, 1) = 1
------------------------------Mike Walker
xDB Systems, Inc
www.xdbsystems.com
------------------------------
Perfect, Mike. Thanks! ------------------------------ +-----------------------------------------------------------+ | I am pleased to report that I had no problems today. | | I had only issues, opportunities, challenges and valuable | | learning experiences. | +------------------------------------------ Jacob S --------+ ------------------------------