Forum Discussion
BrittanyScheid
Qrew Cadet
Hi Kristoffer,
I'm brand new to regex but I'm trying to loop through the users in a List-User field to then create a child record for each. I used the expression and process you indicated above, but it seems to only be returning the first user, not any of the others. I wasn't sure what all the other fields should be set to in the Query step, so I just left them as the defaults. Any help would be greatly appreciated! Thanks!
------------------------------
Brittany Scheid
------------------------------
I'm brand new to regex but I'm trying to loop through the users in a List-User field to then create a child record for each. I used the expression and process you indicated above, but it seems to only be returning the first user, not any of the others. I wasn't sure what all the other fields should be set to in the Query step, so I just left them as the defaults. Any help would be greatly appreciated! Thanks!
------------------------------
Brittany Scheid
------------------------------
KristofferKeen1
2 years agoQuickbase Staff
Hey Brittany-
Looking at your screenshot, the jinja looks correct. So I want to double check:
------------------------------
Kristoffer Keene
------------------------------
Looking at your screenshot, the jinja looks correct. So I want to double check:
- that you grabbed the correct list-user field?
- there is more than 1 user listed in that field for the record you found
- do you have the for each loop after this step?
------------------------------
Kristoffer Keene
------------------------------
- BrittanyScheid2 years agoQrew CadetHi Kristoffer,
Thanks for your response. See my answers to your questions below:
- that you grabbed the correct list-user field? Yes
- there is more than 1 user listed in that field for the record you found. Yes, I've tried multiple various selections and triggered the pipeline several times.
- do you have the for each loop after this step? Yes. See the attached screenshots.
------------------------------
Brittany Scheid
------------------------------- KristofferKeen12 years agoQuickbase StaffHey Brittany-
Figured it out! Even though you could convert theUserList
field into a formula text field and use the regex to split that text field. Here's a way to not need that helper field and use theUserList
field directly in pipelines.
UserList
is an array of objects so you need to extract the email attribute from all the objects and then parse that list.
This Jinja will extract them to create a single string that you can use in regex:{{ a.user_list | map(attribute="email") | join(";") }}
------------------------------
Kristoffer Keene
------------------------------