# Adding field to the periodic group

**URL:** <https://techcommunity.softwareag.com/t/adding-field-to-the-periodic-group/58274>\
**Category:** Forum\
**Tags:** Adabas-Natural, Adabas, Adabas-on-Linux, Adabas-Utilities-on-Open-Systems\
**Created:** [April 18, 2007, 4:20am UTC](https://techcommunity.softwareag.com/t/adding-field-to-the-periodic-group/58274 "2007-04-18T04:20:52Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![yelena](https://avatars.discourse-cdn.com/v4/letter/y/7feea3/32.png) [@yelena](https://techcommunity.softwareag.com/u/yelena)\
**Post date:** [April 18, 2007, 4:20am UTC](https://techcommunity.softwareag.com/t/adding-field-to-the-periodic-group/58274/1 "2007-04-18T04:20:52Z")

</div>

I need to add the field to the periodic group on a big file and can not figure out an easy way to do this, because with adadbm I can add a field only to the end of the file.

I would really appreciate any help.

Thanks  
Yelena

---

<div class="post-metadata">

**Author:** ![Douglas\_Kelly](https://sea1.discourse-cdn.com/techcommunity/user_avatar/techcommunity.softwareag.com/douglas_kelly/32/102_2.png) [@Douglas\_Kelly](https://techcommunity.softwareag.com/u/Douglas_Kelly)\
**Post date:** [April 18, 2007, 11:37am UTC](https://techcommunity.softwareag.com/t/adding-field-to-the-periodic-group/58274/2 "2007-04-18T11:37:23Z")

</div>

classic workaround for this, particularly if you are trying to add an alpha field:

- find an adjacent field with compatible format and expand it. If you need to add a (A3) field, then take one of the PE elements and expand it by 3 (eg A5 to A8) with a filemod. This changes the standard length of that field
- unload and decompress the file
- modify your definition to include the new field, resetting the neighbour field back to its original size
- compress and load

Packed numerics (and some other formats - binary, dates, etc) may require some additional futzing - expand the neighbour field, load the new bytes with valid packed data with a natural program (eg redefine the expanded field A8 as A5/P5, reset the P5, update), then unload/decompress/compress/load

---

<div class="post-metadata">

**Author:** ![yelena](https://avatars.discourse-cdn.com/v4/letter/y/7feea3/32.png) [@yelena](https://techcommunity.softwareag.com/u/yelena)\
**Post date:** [April 18, 2007, 11:06pm UTC](https://techcommunity.softwareag.com/t/adding-field-to-the-periodic-group/58274/3 "2007-04-18T23:06:33Z")

</div>

Wow, never even crossed my mind. Since I had to add just a simple 1 byte alphanumeric filed it was really a great idea.  
Had to dig through utility documentation though for the right options, but it worked just fine.

Thank you so much.  
Yelena

---

<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, 2:39pm UTC](https://techcommunity.softwareag.com/t/adding-field-to-the-periodic-group/58274/4 "2021-04-02T14:39:09Z")

</div>


