Forum Discussion

JamesCarr's avatar
JamesCarr
Qrew Member
2 years ago

Formula URL to Add Records with a Reference Proxy Field

I have a table with lookup fields to related tables. Only one lookup field is required to be populated when adding a record, and that field has a drop down menu made up of a report link to a related table. I can api_addrecord to actually populate the necessary fields except, when I look at the new record, the lookup field is blank and the related fields didn't populate. When I choose to edit the record, the lookup fields immediately populate but I still have to select the drop down value.

Is it possible to make a formula url that will lead to the lookup fields being populated after the call? Also, how do I populate the lookup field with the formul url? Is it even possible?



------------------------------
James Carr
------------------------------

27 Replies

  • The reference field on the right side of the relationship needs to be populated by the API with the value of the key field of the parent record.  Then all the lookup fields will populate.



    ------------------------------
    Mark Shnier (Your Quickbase Coach)
    mark.shnier@gmail.com
    ------------------------------
    • JamesCarr's avatar
      JamesCarr
      Qrew Member

      Having said that, looks like I could use some redesigning. Thanks.



      ------------------------------
      James Carr
      ------------------------------
    • JamesCarr's avatar
      JamesCarr
      Qrew Member

      Hey Mark,

      I thought more about what you said and, before I went into redesign, I managed to get the report link field to populate using the key. Unfortunately, other lookup fields to yet another table are based on an email address field. Those fields don't normally populate until the email address is entered and then the field "clicking" out of the field to let things calculate. Using the formula URL, those fields do not populate until after I choose to edit the newly added record. Any suggestions for how to handle that? Do I need to redesign anything?



      ------------------------------
      James Carr
      ------------------------------
      • JamesCarr's avatar
        JamesCarr
        Qrew Member

        Immediately after I posted this, I thought about what the problem likely is. Dynamic form rules. I had an issue with the lookup working due to case sensitivity so, I have a hidden field that picks up the LCase of the email address. The lookup is done based on that field, which can't be edited. Dynamic form rules are in driven by the email address and the hidden email address fields for setting what sections are visible as well as setting couple of checkboxes.  Will the URL not work because of the Dynamic form rules? Is there another API call I can make that will trigger the form rules after the record is added? I am looking to avoid having the record shown while being edited, if possible. 



        ------------------------------
        James Carr
        ------------------------------