I have 2 record types, totally Sync, with a relationship One Event to Many Instructions, properly related, as I have a custom record field in Event about a sumatory of an Instructions field which is correctly working...
But then, when I query the Events,I retrieve nothing using:
local!instructions: local!events[recordType!Event.relationships.instruction]
So I've tried to fill the relatedRecordData field in the query of events but it keeps retrieving nothing, null data.
local!events: a!queryRecordType(... relatedRecordData: a!relatedRecordData( relationship: recordType!Event.relationships.instruction ), ... ), local!instructions: local!events[recordType!Event.relationships.instruction.idInstruction],
Discussion posts and replies are publicly visible
You can use the 'fields' parameter to get the related record fields when querying the records.
local!event:a!queryRecordType( recordType: cons!REC_TYPE, fields:{ recordType!Event.relationships.instruction }, filters:{}, pagingInfo: a!pagingInfo(1,10) )
Hi Mathurambika,
Thanks for your answer, it works. But it forces me to write every single field in my RT, is it the only solution for my problem?
AFAIK, we have to pass all the related record fields in the 'fields' parameter in order to access their data.
Thanks Mathurambika M
I am new in Appian. Your solution helped me.