SOQL Query error on Drawer Open Accounts-Contacts

  • 1
  • Problem
  • Updated 1 year ago
  • Solved
Primary table is Accounts on a list view page.  Added Drawer to show related Contacts for each Account record in table.   Followed the directions on this page:  https://docs.skuid.com/latest/en/skuid/components/drawers/

Keep getting SOQL error when opening Drawer.   I have the

    Accounts as Primary object

    Contacts model has condition where Account.Id = blank, filterable off
  
    The Before Load Actions on the Drawer Activate Condition and Set Value,
    query Contacts Model, value = {{Id}}.  

Tried several different tweaks and still coming up with this error below.  It has to be something simple I am missing:

SOQL query: SELECT Name,Title,Account.Name,AccountId,Id FROM Contact WHERE (AccountId = 001G000001yaZc7IAE) LIMIT 21 Error:unexpected token: 'G000001yaZc7IAE'

Tried using Account.Id and it did not make a difference

Thanks
Photo of Ann Kukich

Ann Kukich

  • 1,316 Points 1k badge 2x thumb

Posted 1 year ago

  • 1
Photo of Ann Kukich

Ann Kukich

  • 1,316 Points 1k badge 2x thumb
I was able to resolve this by pasting the sample xml from the tutorial page.  Not sure where the error was, as all of the Action Framework settings look the same.   Nice to have the xml example!
Photo of Bill McCullough

Bill McCullough, Champion

  • 12,436 Points 10k badge 2x thumb
Ann,

I think your condition on the Contact model for the drawer was the problem.  The tutorial says to use 'AccountId' as the model field for the condition.  In your posting you have 'Account.Id' (account dot id) as the condition.  Using  'Account.Id' will cause problems.

Thanks,

Bill