MVSFORUMS.com Forum Index MVSFORUMS.com
A Community of and for MVS Professionals
 
 FAQFAQ   SearchSearch   Quick Manuals   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Problem with INDEX

 
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> Application Programming
View previous topic :: View next topic  
Author Message
vkphani
Intermediate


Joined: 05 Sep 2003
Posts: 483
Topics: 48

PostPosted: Thu Oct 06, 2005 11:37 pm    Post subject: Problem with INDEX Reply with quote

Hi,

I have a varible declared in my copybook as below.

Quote:
05 OAA0006-API-OUTPUT-DATA.

10 OAA0006-OUTPUT-BANKS OCCURS 100 TIMES INDEXED BY I.
15 OAA0006-SETT-BANK-ID PIC S9(3)V COMP-3.
15 OAA0006-CLG-BANK-ID PIC S9(3)V COMP-3.


The following statements on index (I) are present in the COBOL program.

Quote:
SET I TO 1
.......
IF I = 101
.......
SET I UP BY 1


I am using the copybook in my program.

Quote:
COPY BOAA0006.


During compilation I am getting the following errors:

Quote:
"OAA0006-SETT-BANK-ID OF OAA0006-API-OUTPUT-DATA" was a table element but was not subscripted or indexed. The first occurrence of the table element was assumed.


Quote:
"OAA0006-CLG-BANK-ID OF OAA0006-API-OUTPUT-DATA" was a table element but was not subscripted or indexed. The first occurrence of the table element was assumed.


Could anybody please help me with this.
Back to top
View user's profile Send private message Send e-mail
vkphani
Intermediate


Joined: 05 Sep 2003
Posts: 483
Topics: 48

PostPosted: Fri Oct 07, 2005 12:15 am    Post subject: Reply with quote

Hi All,

I got the solution.

Earlier My code was like this:

Quote:

MOVE X OAA0006-SETT-BANK-ID(OAA0006-API-OUTPUT-DATA).
MOVE Y OAA0006-CLG-BANK-ID(OAA0006-API-OUTPUT-DATA).



Now I changed these statements as below:

Quote:

MOVE X OAA0006-SETT-BANK-ID(I).
MOVE Y OAA0006-CLG-BANK-ID(I).
Back to top
View user's profile Send private message Send e-mail
Display posts from previous:   
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> Application Programming All times are GMT - 5 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


MVSFORUMS
Powered by phpBB © 2001, 2005 phpBB Group