cobrix icon indicating copy to clipboard operation
cobrix copied to clipboard

Does cobrix support justified, rename clause, and P in PIC clause which scales up and down the value

Open ghost opened this issue 5 years ago • 3 comments

Background [Optional]

A clear explanation of the reason for raising the question. This gives us a better understanding of your use cases and how we might accommodate them.

Question

Does cobrix support justified, rename clause, and P in PIC clause which scales up and down the value

ghost avatar May 19 '20 13:05 ghost

Yes, I think we added support for P some time ago. What's a justified rename clause? A couple of examples may help to understand if we support such PICs or not.

yruslan avatar May 20 '20 14:05 yruslan

LEFT JUSTIFIED PIC 99

if data has a value of 1234 then 34 will be removed and value will come as 12

RIGHT JUSTIFIED PIC 99

if data has a value of 1234 then 12 will be removed and value will come as 34

RENAMES in cobol is used to declare a new data item in terms of an existing data item. The level number will be 66.

66 Fld1 RENAMES FldOld. This is same as declaring Fld1 with same structure of FldOld.

If you want to declare Fld1 with a part of FldOld then u can declare it as...

66 Fld1 RENAMES X THROUGH Y. It means your record will contain only X,Y sub data items.

codealways avatar Jun 01 '20 08:06 codealways

We don't support these clauses at the moment. We might add it to our plans.

yruslan avatar Jun 03 '20 09:06 yruslan