How to delete a front spaces in a data-name/variable in
cobol
Example:-
01 data-name-1 PIC x(20) value " cobol language".
01 data-name-2 PIC x(20).
MOVE data-name-1 to data-name-2.
would like the value of data-name-2 is "cobol language".
Answer Posted / anjibabu
Deepak is partially right.
01 name1 pic a(20) value ' cobol language'.
01 name2 pic a(20).
01 name3 redefines name2 pic a(14) justified right.
PD
move name1 to name3.
display name2.
| Is This Answer Correct ? | 0 Yes | 1 No |
Post New Answer View All Answers
What is inspect in cobol ?
Name the sections present in data division.
What is Pic 9v99 Indicates in COBOL?
What are the different rules for performing sort operation?
i made it to stage 3 of an interview process wednessday they will quiz my knowledge again face to face for an analyst role recruiter said it will be based on Business requirements system is cobol and good ideas what they might ask etc
How to remove 2 duplicate records and copy only one using job control language?
How you can read the file from bottom?
i want to learn mainframe..any websites and material to learn from basic..? my mail id : rajeswaribe2010@gmail.com
What is link edit in cobol?
What is the LINKAGE SECTION used in COBOL?
Can we redefine the field of x(200) to less than 200?
i was faced one question- i have value -00001234.56 Suppress the zeroes and the output should be -1234.56 But Not - 1234.56 spaces should not be available after suppressing the zeroes. logic in jcl and cobol?
if we have " ibm mainframe ",in that how to remove first and last leading space eg:"ibm mainframe" like that the answer we need
Difference between cobol and cobol-ii?
explain sorting techniques in cobol program?