Table
A container contains segments. Each segment belongs to only one tablespace. A tablespace may have multiple segments. All segments of a given segment are in the tablespace associated with the segment. Segment will never span the table
Spatial Boundary. The tablespace itself can have one or more related data files. A partition of a given segment in a tablespace is completely contained in a data file. However, segments can have segments from multiple different data files.
The tablespace is shown in Figure 3-3.
Figure 3-3 The tablespace contains two data files, three segments, and four segments.
Figure 3-3 shows a tablespace named user_data. There are two data files: user_data01 and user_data02. Three segments are allocated: T1, T2, and I1 (maybe two tables and one index ). This tablespace is allocated with four segments, each representing a group of database blocks that are logically allocated consecutively. Segment T1 contains two segments, which are in different files. Each segment T2 and I1 have a CIDR block. If the tablespace requires more space, you can adjust the size of the data file that has been allocated to the tablespace, or you can add a third data file.
A tablespace is a logical storage container in Oracle. As a developer, we will create segments in the tablespace without going deep into the original "file-level ". We do not want to allocate segments in a specific file (of course, this is also acceptable, but we generally do not do this ). Instead, we will create objects in the tablespace, and Oracle will be responsible for the rest of the work. If the DBA decides to move data files on the disk at a certain time in the future to make the I/O distribution more even, it does not matter to us and it will not affect our processing at all.