# how to get the actual length of the data

**URL:** <https://techcommunity.softwareag.com/t/how-to-get-the-actual-length-of-the-data/194830>\
**Category:** Forum\
**Tags:** Adabas-Natural, Natural, Natural-on-Mainframes\
**Created:** [May 30, 2017, 11:38am UTC](https://techcommunity.softwareag.com/t/how-to-get-the-actual-length-of-the-data/194830 "2017-05-30T11:38:45Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Murthy\_P\_V\_S\_R](https://avatars.discourse-cdn.com/v4/letter/m/ad7895/32.png) [@Murthy\_P\_V\_S\_R](https://techcommunity.softwareag.com/u/Murthy_P_V_S_R)\
**Post date:** [May 30, 2017, 11:38am UTC](https://techcommunity.softwareag.com/t/how-to-get-the-actual-length-of-the-data/194830/1 "2017-05-30T11:38:45Z")

</div>

Hi,

On existing map/screen, there is a field/column Email ID which is 50 characters in length get populated from one of the adabase file having filed datatype A50. If the actual data stored in the DB file is just for example only 25characters then how do I get the lenght of actual stored data.  
Is there any system function/variable which will give actual data stored in DB file?

Thanks & Regards  
MP

---

<div class="post-metadata">

**Author:** ![Steve\_Robinson](https://sea1.discourse-cdn.com/techcommunity/user_avatar/techcommunity.softwareag.com/steve_robinson/32/107_2.png) [@Steve\_Robinson](https://techcommunity.softwareag.com/u/Steve_Robinson)\
**Post date:** [May 30, 2017, 1:38pm UTC](https://techcommunity.softwareag.com/t/how-to-get-the-actual-length-of-the-data/194830/2 "2017-05-30T13:38:21Z")

</div>

Assuming embedded blanks are not valid, an EXAMINE emailid for first ’ ’ giving position #position would suffice.

---

<div class="post-metadata">

**Author:** ![Murthy\_P\_V\_S\_R](https://avatars.discourse-cdn.com/v4/letter/m/ad7895/32.png) [@Murthy\_P\_V\_S\_R](https://techcommunity.softwareag.com/u/Murthy_P_V_S_R)\
**Post date:** [May 30, 2017, 2:21pm UTC](https://techcommunity.softwareag.com/t/how-to-get-the-actual-length-of-the-data/194830/3 "2017-05-30T14:21:10Z")

</div>

Thank you Steve Robinson for your response.

Just I have used the EXAMINE #EMAIL-ID FOR ’ ’ DELETE GIVING LENGTH #EMAIL-LEN.

and I got the desired output.

Once again thank you a lot.

Regards  
Murthy

---

<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:** [May 30, 2017, 9:28pm UTC](https://techcommunity.softwareag.com/t/how-to-get-the-actual-length-of-the-data/194830/4 "2017-05-30T21:28:14Z")

</div>

A more generic solution is

```auto
EXAMINE #EMAIL-ID FOR PATTERN '.' GIVING LENGTH #EMAIL-LEN
```

---

<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:38pm UTC](https://techcommunity.softwareag.com/t/how-to-get-the-actual-length-of-the-data/194830/5 "2021-04-02T15:38:35Z")

</div>


