It is possible to use pulldata or indexed-repeat in instance_name?

990
15
01-03-2023 05:50 PM
JJ_Reyes
Occasional Contributor

I'm trying to access either parent data or data inside a repeat to label my inbox records. I've tried using indexed-repeat and pulldata in the instance_name field, but neither seem to work.

Is it possible to access related tables either "up" or "down" to label the inbox records?

0 Kudos
15 Replies
DougBrowning
MVP Esteemed Contributor

I have seen these types of issues with pulldata.  Usually the workaround is to put the pulldata in a field by itself then call that field instead.  Give that a shot.

0 Kudos
JJ_Reyes
Occasional Contributor

Hmmm. I have not had any luck yet. Here is what I have tried so far as to put pulldata in a separate field. 

- Use a note field with Bind null
- Use a text field with calculationMode (have tried always and whenEmpty). Even here it doesn't pick it up on the fly, but would if saved to the database. 

Ultimately, I'm trying to get the data without having to save it in a new field in the parent/child form to avoid data duplication. Do you have any examples of forms this has worked for you @DougBrowning?

0 Kudos
DougBrowning
MVP Esteemed Contributor

Wait why would you use pulldata into your own form?  Can you post the form or a sample form of what you are trying.  Just like a mechanic you got to bring the car in. 🙂

0 Kudos
JJ_Reyes
Occasional Contributor

Sure. Paired down example attached.

(Yes, this survey is just repeat section. I'm trying to pull in data from the parent. I could add all the parent info to the survey, then I'd have to pull in info from the child also - that would be index-repeat method....)

0 Kudos
DougBrowning
MVP Esteemed Contributor

Is your WDiam getting populated in the form?  It looks like you may be hitting an external service?  Are you online when doing this?  You mentioned repeats but there are no repeats in this form.

Sorry I am not sure.

0 Kudos
JJ_Reyes
Occasional Contributor

Thanks for reviewing this Doug. I am not intending that WDiam would actually be a persistent field in this survey. This survey is the child table of a feature layer. WDiam is a field in the parent table. I'm hoping to pull WDiam from the parent.

I did find the post that mentions pulldata @layer should bring in my token, so I do actually need to change pulldata javascript to pulldata @layer.....

0 Kudos
JJ_Reyes
Occasional Contributor

Hi @DougBrowning - not sure if you saw my last response and had a chance to look at my form. Any ideas would be appreciated!

0 Kudos
DougBrowning
MVP Esteemed Contributor

I think you had lost me.  You need the field in there if you want to use.  Not sure how you can ref a field that is not there?   If I need a parent field in a child I just add the field and call it RepeatNameFieldA then have a calc of FieldA to bring it into the child.  We use it all the time on our keys and state code so we can filter at any level.  

0 Kudos
JJ_Reyes
Occasional Contributor

Ok thanks. I think I am missing a big concept on the parent/child. Using pulldata @layer must be overkill for bringing parent data into child - even when the parent data is not used in the form. I'll look into this.

0 Kudos