16.20 - Example: Which AMPs Contain the Rows of a Table - Teradata Database

Teradata Vantageā„¢ - SQL Functions, Expressions, and Predicates

prodname
Advanced SQL Engine
Teradata Database
vrm_release
16.20
created_date
March 2019
category
Programming Reference
featnum
B035-1145-162K

The following query shows which AMPs contain the rows of a table.

sel col1, hashamp(hashbucket(hashrow(col1)) 
          map = map1count3 colocate using u1_tabm1c3) 
          (named "which amp?") 
from u1.tabm1c3 order by 1;

       col1   which amp?
-----------  -----------
          0            3
          1            2
          2            3
          3            2
          4            2
          5            2
          6            3
          7            2
          8            3
          9            1