ibmi-brunch-learn

Announcement

Collapse
No announcement yet.

Error in Array definition

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Error in Array definition

    Below array definition:

    0073.00 d@berth_data 12 dim(10)
    0074.00 d @berth_number 2 overlay(@berth_data:1)
    0075.00 d @berth_volume 10 0 overlay(@berth_data:3)



    When compiling I get folowing errors (running release V5R3M0)

    ======> aa
    *RNF3703 20 a 007300 The subfield or parameter definition is not specified
    within a group.
    73 d @berth_number 2 overlay(@berth_data:1)
    ======> aa bbbbbbb
    *RNF3703 20 a 007400 The subfield or parameter definition is not specified
    within a group.
    *RNF3601 20 b 007400 Keyword is not allowed for a field definition; keyword
    ignored.
    74 d @berth_volume 10 0 overlay(@berth_data:3)
    ======> aa bbbbbbb
    *RNF3703 20 a 007500 The subfield or parameter definition is not specified

  • #2
    Re: Error in Array definition

    I believe you are missing the "DS" on line 73 making it a data structure.
    Never trust a dog to watch your food.

    Comment


    • #3
      Re: Error in Array definition

      Hi,

      you have to define as follows:
      PHP Code:
      D                 DS                                               
      @Berth_Data                         Dim(10)                      
      D   @Beth_Number                 2A   Overlay(@Berth_Data)         
      D   @Beth_Volume                10S 0 Overlay(@Berth_Data: *Next
      Note: You do not nead any length for @Berth_Data, because it is already defined by the two fields (@Berth_Number, @Berth_Data) that overlay this field.

      Birgitta

      Comment

      Working...
      X