Oracle and DB2, Comparison and Compatibility/Storage Model/Tables/DB2

From Wikibooks, open books for an open world
Jump to navigation Jump to search

DB2[edit | edit source]

Because tables are logical structures, they are represented in DB2 the same way as they are in Oracle – Tables contain Rows and Columns. The analogous structures that can be seen in the two databases are that DB2 stores data in Pages, and Oracle uses Blocks. Both pages and blocks are fetched as a single contiguous chunk as extents. Within Oracle, extents are organized into segments, in DB2 they are managed in containers. Both containers and segments are contained within DB2 and Oracle tablespaces respectively.

DB2 Tables in a Tablespace
DB2 Table in a Tablespace.jpg