Hitachi

Hitachi Advanced Database Application Development Guide


5.9.2 Work table execution

If work table execution is used as the method for processing SELECT DISTINCT, HADB creates a work table containing the retrieval result. Then, HADB sorts data in the work table and performs deduplication.

The following shows an example of work table execution.

■ SELECT statement to be executed
SELECT DISTINCT "C1" FROM "T1"
Figure 5‒20: Processing method for work table execution

[Figure]

Explanation:

  1. Retrieves table T1, and then stores the value of column C1 of table T1 in the work table.

  2. Performs data sort processing and deduplication for the work table created in step 1.