# Map array definition issue

**URL:** <https://techcommunity.softwareag.com/t/map-array-definition-issue/206188>\
**Category:** Forum\
**Tags:** Adabas-Natural, Natural, Natural-on-Mainframes\
**Created:** [November 22, 2019, 11:00am UTC](https://techcommunity.softwareag.com/t/map-array-definition-issue/206188 "2019-11-22T11:00:27Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![Gurpreet\_kaur1](https://avatars.discourse-cdn.com/v4/letter/g/ed8c4c/32.png) [@Gurpreet\_kaur1](https://techcommunity.softwareag.com/u/Gurpreet_kaur1)\
**Post date:** [November 22, 2019, 11:00am UTC](https://techcommunity.softwareag.com/t/map-array-definition-issue/206188/1 "2019-11-22T11:00:27Z")

</div>

hello, I created a map, and had few array fields defined into. each array field was defined as below -

Name #MAP-ARRAY.#MAP-COL-GRADE-ARRA Top Dim 100\_\_\_\_\_\_\_\_\_ 1\_\_\_\_\_\_\_\_\_\_ 1\_\_\_\_\_\_\_\_\_\_

Dimensions Occurrences Starting from Spacing  
1 . Index vertical 10\_ #COL-START\_ 0 Lines  
0 . Index horizontal 1\_\_ \_\_\_\_\_\_\_\_\_\_\_ 1 Columns  
0 . Index (h/v) V 1\_\_ \_\_\_\_\_\_\_\_\_\_\_ 0 Cls/Ls

when I stowed the map, and ran using the program. it showed me values at 17 occurence of the array even though I defined only 10 occurrences in the map. please see below the data - NAJH at the bottom shows which shoudnt be showing up

## SSS11001 SYNCHRO SCHEDULING SYSTEM 22/11/19 TEST VEHICLE/SSS WIP Summary 09:47:52

Car Series: J112  
COLOR-GRADE PAINT WIP SSS STOCK SSS WIP

* * *

```
          W040 W070 W080 Front Rear Sched Loading Loaded Checking  

```

KY0DEF 31  
KY0L 8 39 6  
KY0H 23 52 3  
NAJDEF 11  
NAJDY 22 2  
NAJL 1 24 3  
NAJH 10 41 4  
QABDEF 34  
QABDY 48 2  
QABL 10 109 2

* * *

-Enter-PF1–PF2—PF3—PF4—PF5—PF6—PF7—PF8—PF9—PF10–PF11–PF12-  
Exit Main Update Page Page Expand Left Right  
Up Down  
NAJH

I listed the map and noticed below -  
/

- MAP2: VALIDATION \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*  
003T #MAP-ARRAY.#MAP-COL-GRADE-ARRAY (17) (AD=OIL ) /\*.01U008 A008 8
- MAP2: END OF MAP \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*  
END

There is a validation in there which i can see when I list the map. But I dont know how it appeared at first place and how to remove this.  
This validation also prevents me to define the occurrences of the array less than 17. it throws incorrect index error when I stow the map. I have attached detailed screenshots and problem in word doc. if somebody could help please.

[Map array Issue.docx](https://techcommunity.softwareag.com/uploads/short-url/sTD7fvhGn1BaLX4MwqVHCZUrINB.docx) (898 KB)

---

<div class="post-metadata">

**Author:** ![George\_Cooper](https://sea1.discourse-cdn.com/techcommunity/user_avatar/techcommunity.softwareag.com/george_cooper/32/7831_2.png) [@George\_Cooper](https://techcommunity.softwareag.com/u/George_Cooper)\
**Post date:** [November 24, 2019, 2:19am UTC](https://techcommunity.softwareag.com/t/map-array-definition-issue/206188/2 "2019-11-24T02:19:25Z")

</div>

Hi Gurpreet,

If you haven’t solved this yet, it looks to me like your unwanted 17’th occurrence at the bottom of the screen is just an extraneous field accidentally left on the map when you were building it. In the map editor you should be able to scroll to the bottom, 24th line it looks like, and delete that single field with a “.D”. It obviously doesn’t belong there below the PF key description lines.

Looking at the lines you listed, line 205 is not any type of validation rule, it just causes the hard-coded 17th occurrence of the array to be displayed. I don’t know why it shows up in the source below the comment line \* MAP2: VALIDATION. It only caused an index error when you reduced the array size from 100 to 10, since occurrence (17) no longer existed.

> [@](#):
>
> - MAP2: VALIDATION \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*  
> 003T #MAP-ARRAY.#MAP-COL-GRADE-ARRAY (17) (AD=OIL ) /\*.01U008 A008 8
> - MAP2: END OF MAP \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*

Hope that helps,  
George

---

<div class="post-metadata">

**Author:** ![Gurpreet\_kaur1](https://avatars.discourse-cdn.com/v4/letter/g/ed8c4c/32.png) [@Gurpreet\_kaur1](https://techcommunity.softwareag.com/u/Gurpreet_kaur1)\
**Post date:** [November 25, 2019, 10:37am UTC](https://techcommunity.softwareag.com/t/map-array-definition-issue/206188/3 "2019-11-25T10:37:18Z")

</div>

HI George  
Many thanks for your reply.  
I have already tried doing .D on 23rd line of the map, it didnt seem to help and problem still persisted.  
I have been still struggling to solve this yet. I guess if I am able to get rid of this validation from MAP this may vanish.

---

<div class="post-metadata">

**Author:** ![George\_Cooper](https://sea1.discourse-cdn.com/techcommunity/user_avatar/techcommunity.softwareag.com/george_cooper/32/7831_2.png) [@George\_Cooper](https://techcommunity.softwareag.com/u/George_Cooper)\
**Post date:** [November 25, 2019, 11:16am UTC](https://techcommunity.softwareag.com/t/map-array-definition-issue/206188/4 "2019-11-25T11:16:27Z")

</div>

Sorry to hear you are still having trouble with your map.

Keep in mind that the .D command only deletes a single field, and you have to type the .D on top of the field you want to delete.

If the 23rd line only has the one field you need to delete, you could also do a …D line command in col 1 to delete the whole line. That would also allow you to …I to insert a blank line above the PF Key description lines, if you want them shifted down to the very bottom of the screen.

Good luck.  
George

---

<div class="post-metadata">

**Author:** ![Gurpreet\_kaur1](https://avatars.discourse-cdn.com/v4/letter/g/ed8c4c/32.png) [@Gurpreet\_kaur1](https://techcommunity.softwareag.com/u/Gurpreet_kaur1)\
**Post date:** [November 25, 2019, 11:42am UTC](https://techcommunity.softwareag.com/t/map-array-definition-issue/206188/5 "2019-11-25T11:42:49Z")

</div>

Hi George,  
I tried what you suggested. The map isnt able to stow now and throws a stow error. it is getting more intresting and I am clueless. ☹

Attached the error screenshots  
[Error.docx](https://techcommunity.softwareag.com/uploads/short-url/w785w9R1jxrtm6zdZdjsLxVCcM9.docx) (571 KB)

---

<div class="post-metadata">

**Author:** ![Ralph\_Zbrog](https://sea1.discourse-cdn.com/techcommunity/user_avatar/techcommunity.softwareag.com/ralph_zbrog/32/78_2.png) [@Ralph\_Zbrog](https://techcommunity.softwareag.com/u/Ralph_Zbrog)\
**Post date:** [November 25, 2019, 5:23pm UTC](https://techcommunity.softwareag.com/t/map-array-definition-issue/206188/6 "2019-11-25T17:23:25Z")

</div>

The compiler will ignore line 0069 because it is a comment. It issues an error because after placing Down at column 50, you try to place #MAP-COL-GRADE-ARRAY (17) at column 3 of the same line.

I thought George’s suggestion might work. (Page down to the bottom of the map; delete #MAP-COL-GRADE-ARRAY (17).)

Perhaps this will delete it:

- increase #MAP-COL-GRADE-ARRAY occurrences to 17

- STOW (probably will fail)

- decrease #MAP-COL-GRADE-ARRAY occurrences to 10

- STOW

If that fails, I think you will have to create the map from scratch.

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/techcommunity/original/3X/c/d/cd19967bb605d28a72d77eb83a1cae22f3df2eb8.svg) [@system](https://techcommunity.softwareag.com/u/system)\
**Post date:** [April 2, 2021, 3:43pm UTC](https://techcommunity.softwareag.com/t/map-array-definition-issue/206188/7 "2021-04-02T15:43:49Z")

</div>


