HASH functions in Teradata

In order to find the data distribution over all the AMPs, the following query can be used.
We can easily identify the odd distribution easily.

SELECT 
HASHAMP (HASHBUCKET (HASHROW ())) AS “AMP#”, 
COUNT (*) FROM 
GROUP BY 1 
ORDER BY 2 DESC;


There are HASHROW, HASHBUCKET, HASHAMP and HASHBAKAMP functions.

Example:
SELECT
HASHROW ('Teradata')   AS "Hash Value",
HASHBUCKET (HASHROW ('Teradata')) AS "Bucket Num",
HASHAMP (HASHBUCKET (HASHROW ('Teradata'))) AS "AMP Num",
HASHBAKAMP (HASHBUCKET (HASHROW ('Teradata')))  AS "AMP Fallback Num" ;