Returns a bit string that is the logical AND of the elements of a bit string array.
ALL(x)
x is an array expression. If x is not a bit string array, it is converted to one.
DCL BIT_TEST(3) BIT(5) INITIAL ('10011'B, '10111'B, 10110'B); DCL BIT_RES BIT(5); BIT_RES = ALL(BIT_TEST); /* returns '10010'B */
Description
The ALL function returns a bit string whose length is equal to the length of the longest bit string value in the array. Each bit of the result is 1 if and only if the corresponding bit exists and has the value 1 in every element of the array.