33.3.1 Merging all chunks in a table
This example merges under the following conditions all chunks in table TABLE01 into a new chunk:
-
CHUNK is specified when table TABLE01 is defined (table TABLE01 is a multi-chunk table).
-
B-tree, text, and range indexes are defined for table TABLE01.
-
Data was imported into table TABLE01 by applying the background-import facility twice.
-
Table TABLE01 has chunks with chunk IDs 1, 2, and 3.
-
The chunk ID of table TABLE01's current chunk is 3.
This example uses the following procedure to execute the adbmergechunk command.
- Procedure
-
-
Create a merge chunk option file.
-
Execute the adbmergechunk command.
-
Using an example, the following subsections explain each of these steps.
- Organization of this subsection
(1) Creating a merge chunk option file
This example creates a merge chunk option file and specifies merge chunk options in that file.
- Example of a merge chunk option file
-
set adb_mergechunk_rthd_num = 3 set adb_mergechunk_scan_buff_size = 2 :
(2) Executing the adbmergechunk command
adbmergechunk -u ADBUSER01 ...1 -p '#HelloHADB_01' ...2 -z /home/adbmanager/merge_file/mergechunk_opt.txt ...3 -m 'January 2014' ...4 -c ALL ...5 TABLE01 ...6
- Explanation:
-
-
Specifies the authorization identifier of the HADB user who executes the adbmergechunk command.
-
Specifies the password for the authorization identifier that is specified in the -u option.
-
Specifies the absolute path name of the merge chunk option file created in (1) Creating a merge chunk option file.
-
Specifies a comment to be set in the merge-target chunk.
-
Specifies ALL in the -c option to merge all chunks in the target table (TABLE01).
This example merges chunks with chunk IDs 1, 2, and 3. After the adbmergechunk command has executed, the merge-target chunk becomes the current chunk.
-
Specifies the table to be processed (TABLE01).
-