There is an issue with some of the newer 8.7.x BIFs (*LEN, *SCAN, *SCANR) where the result field is numeric
REF numeric fields cannot be used and it will be stopped by this false error message Y2V0430
CA 2E 8.7.4
There is a PTF available to resolve the described issue.
Please open a Broadcom Support Case to request the fix.