If you live outside the United States, by submitting your email address you consent to having your personal data transferred to and processed in the United States.
Issue the READ instruction twice after positioning to the desired value with SETLL. If the value from the second READ matches the value that you saved from the first READ, you know you have the second duplicate.
You could also use CHAIN instead of SETLL and the first READ. A CHAIN instruction can do both functions in a single operation. Then issue a READ and compare its value to the one you saved from CHAIN. Again, if it matches, you know you have read the second of duplicate values.
Am not sure, whether you can directly Read the Second duplicate Record.
But, You can set the Pointer using SETLL and you can read the records sequentially(Second Read Record would be the Required Second duplicate).
Or, If you want to Read the Last Duplicate Record, You can set the pointer using SETGT and read the Prior Records using READP
Pradeep.
Issue the READ instruction twice after positioning to the desired value with SETLL. If the value from the second READ matches the value that you saved from the first READ, you know you have the second duplicate.
You could also use CHAIN instead of SETLL and the first READ. A CHAIN instruction can do both functions in a single operation. Then issue a READ and compare its value to the one you saved from CHAIN. Again, if it matches, you know you have read the second of duplicate values.
Tom
Input primary, level indicators, and a counter.