SQL Query + JSON to show and change values of "editable text"

Hi all,

I'm trying to do the following:

Show some fields of different tables depending on a JSON and be able to edit directly to MYSQL.

I have tblclients and tblcontacts.

So first query is: getClients:

SELECT tblclients.userid, tblclients.company, tblcontacts.userid, tblcontacts.firstname, tblcontacts.email 
FROM tblclients
INNER JOIN tblcontacts
ON tblclients.userid = tblcontacts.userid;

With this, I'm able to know which contacts (email and first name) belong to each company.

Then, because I am running this APP on Missiveapp, I want to change the values shown, depending on the email I have opened, I need to run a JSON SQL:


SELECT * FROM {{ getClients.data }} where {{ getClients.data.email}} = ANY({{getCurrentConversation.data.email_addresses.map(x => x.address.toLowerCase())}})

I have set the "getCurrentConversation" to selector: conversation, as the manual says.

The default value for editableText3, which is the email field is:

{{ test.data.email['0']}}

and so on, for the others: .company and. firstname

Then, query3 to upload changes

as a trial, I want to change for instance company name:

So: editableText1:

{{ test.data.company['0']}}


Not showing the proper or any field.


Many thanks in advance!!

Hey @Bannedi! Happy to help here. It seems like the values in your editableTexts isn't evaluating to anything. Can you open up your State panel, check out test, expand out data then company? Do you see any data there? A screenshot would be helpful! If there's no data in there, could you share a screenshot of your test query itself?