if the TS had searched using the same words used to post the request he would have the solution already
hint search the forums with
the tool/language REXX
what primary secondary allocation
search argument crossing the box search for all terms
REXX PRIMARY SECONDARY ALLOCATION
looks like around here associative/data mining logic is a bit flaky
Try LISTDSI function in REXX ... SYSPRIMARY would give you the primary allocation and SYSSECONDS would give you the secondary allocations.. there are lot more information you can obtain using LISTDSI ...