Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...


What is wrong with the following data declaration?
01 W-DATE PIC X(6).
05 DD PIC 99.
05 MM PIC 99.
05 YY PIC 99.
(a) Nothing is wrong.
(b) Under W-DATE all level 05 items are having a PIC 99 but
level
01 has PIC X(6).
(c) PIC can't be specified for a group item.
(d) DD, MM, and YY are invalid datanames.

Answers were Sorted based on User's Feedback



What is wrong with the following data declaration? 01 W-DATE PIC X(6). 05 DD PIC 99. ..

Answer / elite group

c) PIC clause can't be specified the group item

Is This Answer Correct ?    18 Yes 0 No

What is wrong with the following data declaration? 01 W-DATE PIC X(6). 05 DD PIC 99. ..

Answer / rohit

c) PIC can't be specified for a group item.

Is This Answer Correct ?    8 Yes 0 No

What is wrong with the following data declaration? 01 W-DATE PIC X(6). 05 DD PIC 99. ..

Answer / craig

01 W-DATE PIC X(6).
05 DD PIC 99.
05 MM PIC 99.
05 YY PIC 99.

is incorrect.

01 W-DATE.
05 DD PIC 99.
05 MM PIC 99.
05 YY PIC 99.
Is correct, and W-DATE has an implied picture clause of
PIC X(6). Group items are always character in usage. To
use a group item that requires another picture clause, you
must do a redefines, ie.
01 W-DATE-NUM PIC 9(6).
01 W-DATE PIC X(6) REDEFINES W-DATE-NUM.
05 DD PIC 99.
05 MM PIC 99.
05 YY PIC 99.

Is This Answer Correct ?    5 Yes 1 No

What is wrong with the following data declaration? 01 W-DATE PIC X(6). 05 DD PIC 99. ..

Answer / craig

In previous answer,

01 W-DATE-NUM PIC 9(6).
01 W-DATE REDEFINES W-DATE-NUM.
05 DD PIC 99.
05 MM PIC 99.
05 YY PIC 99.

should be the code block at the bottom, sloppy cut and
paste, sorry.

Is This Answer Correct ?    4 Yes 0 No

What is wrong with the following data declaration? 01 W-DATE PIC X(6). 05 DD PIC 99. ..

Answer / sachin

We never specified pic clause on group level item.

Is This Answer Correct ?    1 Yes 0 No

What is wrong with the following data declaration? 01 W-DATE PIC X(6). 05 DD PIC 99. ..

Answer / anshu puri

cobol dont allow to use PIC clause at 01 level

Is This Answer Correct ?    2 Yes 7 No

Post New Answer

More COBOL Interview Questions

2)Where the Plan is located in CICS-DB2?

1 Answers   IBM,


wht is the difference between goto and perform stmts

7 Answers   DELL,


can we use full outer join with cursors declared in cobol program?

2 Answers  


Q:what is the difference between the variable length and fixed lenght.how it varies in the cobol.

12 Answers   CTS, Wipro,


How is sign stored in a comp-3 field?

7 Answers  


Which division and paragraphs are mandatory for a COBOL program?

0 Answers  


How to read the last 100 records from a COBOL file. The file contains N number of records.

11 Answers   IBM,


consider the following piece of code 01 GROUP-ITEM 05 AMOUNT-1 PIC 99V9 USAGE COMP VALUE 50 05 AMOUNT-2 PIC 9(4)V99 USAGE COMP MOVE ZERO TO GROUP-ITEM ADD 50 TO AMOUNT-1 what will be the content of AMOUNT-1? a.50 b.100 c.0 d.unpredictable

10 Answers   TCS,


what will happen if pass values more than 100 using PARM parameter?

1 Answers  


what is Reentrancy and Quasi-reentrancy?

1 Answers  


Can we MOVE X(9) to 9(9) OR 9(9) to X(9)? If yes what are the ways for doing this?

12 Answers   T systems, Tech Mahindra,


What is the meaning of 'Eject' verb in cobol?

2 Answers   TCS, Wipro,


Categories