How to use a bit wise operation to mask part (one bit) of a data element?
search cancel

How to use a bit wise operation to mask part (one bit) of a data element?

book

Article ID: 54795

calendar_today

Updated On:

Products

Realia REALIA- MISC

Issue/Introduction

Chapter 11 of the Cobol Reference Guide describes the MLI_AND, which performs a bitwise logical AND function.

CALL 'MLI_AND' USING source destination

CALL 'MLI_AND' USING source1 source2 destination

This function performs a bitwise logical AND function. All the operands must have the same PICTURE and a length of one, two, or four bytes.

The first form does a logical AND of the source data item with the destination data item, leaving the result in destination.

The second form does a logical AND of the source1 and source2 operands together and leaves the result in destination.

Environment

Release:
Component: REAL2