Skip to main content
Question

Jinja to compare values of fields in two different tables

  • January 30, 2023
  • 0 replies
  • 257 views

Forum|alt.badge.img+6
I have a Pipeline that when a record is created or updated in a table, I need to search a second table to find the Project Code that matches from the created record, then update a field in the second table with some values. The key is matching the Project Code field between the two tables before updating a field value. 
PIPELINE:
On New Event Table 1: Record is created or updated (captures Project Code)
Search Table 2: Search for Project Code that matches Project Code in Table 1
    Update the Portfolio field in table 2 with specified value.

I have been unable to figure out the Jinja code in the Search step to compare the Project Codes between the tables. Any help is appreciated!

------------------------------
Amy Gosz
------------------------------
This topic has been closed for replies.

Forum|alt.badge.img+15
  • Quickbase Alumni
  • January 30, 2023
Amy,

You can find the record you need with out Jinja.   Assuming that the two fields are

[Code in Table One]  Field ID 10
[Code in Table Two]  Field ID 20

In the Advanced Query of your Search Step on Table Two you would put

{20.EX.'{{a.code_in_table_one}}'}

This is the Quickbase Query not Jinja.  You can read more here:

https://helpv2.quickbase.com/hc/en-us/articles/4418310913684

------------------------------
Don Larson
------------------------------