# LDA Object for Using as PDA

**URL:** <https://techcommunity.softwareag.com/t/lda-object-for-using-as-pda/189714>\
**Category:** Forum\
**Tags:** Adabas-Natural, Natural, Natural-on-Mainframes\
**Created:** [July 17, 2016, 5:51pm UTC](https://techcommunity.softwareag.com/t/lda-object-for-using-as-pda/189714 "2016-07-17T17:51:13Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Shashank\_Gite1](https://sea1.discourse-cdn.com/techcommunity/user_avatar/techcommunity.softwareag.com/shashank_gite1/32/351_2.png) [@Shashank\_Gite1](https://techcommunity.softwareag.com/u/Shashank_Gite1)\
**Post date:** [July 17, 2016, 5:51pm UTC](https://techcommunity.softwareag.com/t/lda-object-for-using-as-pda/189714/1 "2016-07-17T17:51:13Z")

</div>

Dear Natural Experts,

It might be a silly question but I am confused and do not have system write now to try it.

I have defined my Variables in an LDA object say LDA1 now I have to pass this complete LDA to a subprogram to be used as PDA.  
Can I use same LDA object LDA1 in “DEFINE DATA LOCAL” of my Program and in “DEFINE DATA PARAMETER” of my Subprogram?

Please advice . Thanks  
Shashank

---

<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:** [July 17, 2016, 6:58pm UTC](https://techcommunity.softwareag.com/t/lda-object-for-using-as-pda/189714/2 "2016-07-17T18:58:47Z")

</div>

You can’t use an LDA as a PDA but you can use a PDA as an LDA.

```auto
PARAMETER USING lda /* <-- invalid
LOCAL USING pda /* <-- valid
```

---

<div class="post-metadata">

**Author:** ![Shashank\_Gite1](https://sea1.discourse-cdn.com/techcommunity/user_avatar/techcommunity.softwareag.com/shashank_gite1/32/351_2.png) [@Shashank\_Gite1](https://techcommunity.softwareag.com/u/Shashank_Gite1)\
**Post date:** [July 17, 2016, 7:42pm UTC](https://techcommunity.softwareag.com/t/lda-object-for-using-as-pda/189714/3 "2016-07-17T19:42:39Z")

</div>

> [@Ralph Zbrog](#):
>
> You can’t use an LDA as a PDA but you can use a PDA as an LDA.
> 
> ```auto
> PARAMETER USING lda /* <-- invalid
> LOCAL USING pda /* <-- valid
> ```

You mean I can use the same Object defined as PDA in my Main Program and Subprogram/Subroutine?

---

<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:** [July 17, 2016, 8:36pm UTC](https://techcommunity.softwareag.com/t/lda-object-for-using-as-pda/189714/4 "2016-07-17T20:36:18Z")

</div>

Yes. the calling routine will contain

```auto
LOCAL USING pda
```

and the subprogram/subroutine will have

```auto
PARAMETER USING pda
```

---

<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:36pm UTC](https://techcommunity.softwareag.com/t/lda-object-for-using-as-pda/189714/5 "2021-04-02T15:36:32Z")

</div>


