Skip to main content
Inspiring
Apr 27, 2025 5:11 AM UTC
Question

How to Dynamically Pass Fields to a!queryRecordType in an Expression Rule?

I'm trying to build a reusable expression rule that queries a RecordType in Appian.
I want to pass the fields dynamically via rule inputs to control which fields are selected during the query.

2 replies

Participating Frequently
Apr 27, 2025 7:07 AM UTC

Hi. You need to change the data type of your rule input "fields" to Record Field and remove the double quotes from your record type fields. See this example:

{
  recordType!SB Need.fields.id,
  recordType!SB Need.fields.name,
}

Inspiring
Apr 27, 2025 7:11 AM UTC

I was searching for this data type but couldn't able to find it.
Thank you, now I got the exact name of this data type.