Filter Salesforce Records with Flow Service API Errors | Community
Skip to main content
Level 1
March 4, 2026
Question

Filter Salesforce Records with Flow Service API Errors

  • March 4, 2026
  • 1 reply
  • 8 views

Hello,

I am currently setting up a source flow from Salesforce CRM. I am following this guide to filter ingestion. https://experienceleague.adobe.com/en/docs/experience-platform/sources/api-tutorials/filter#specify-filtering-conditions-for-ingestion

 

I get an error message when the flow runs.

 

The API request to Salesforce failed. Request Url: /services/data/v59.0/query?q=SELECT+FirstName+FROM+Contact+WHERE+`FirstName`+LIKE+'Ell%25'+AND+(LastModifiedDate+<+2026-03-04T04%3a45%3a00Z), Status Code: BadRequest, Error message: [{"message":"\nSELECT FirstName FROM Contact WHERE `FirstName` LIKE 'Ell%' AND (LastModifiedDate\n ^\nERROR at Row:1:Column:36\nunexpected token: '`'","errorCode":"MALFORMED_QUERY"}]

 

This error message could be because of the ` character used in the query. `FirstName`

Salesforce does not accept ` characters.

The connection spec for Salesforce accepts filters but seems to have the "columnNameEscapeChar" set to ` which is probably not correct?

 

 

```

"filterAtSource": {

                        "enabled": true,

                        "queryLanguage": "SQL",

                        "logicalOperators": [

                            "and",

                            "or",

                            "not"

                        ],

                        "comparisonOperators": [

                            "=",

                            "!=",

                            "<",

                            "<=",

                            ">",

                            ">=",

                            "like",

                            "in",

                            "isNull",

                            "isNotNull"

                        ],

                        "columnNameEscapeChar": "`",

                        "valueEscapeChar": "'"

                    }

```

 

Has anyone been able to filter Salesforce records using PQL?

1 reply

PeterHu3Author
Level 1
March 4, 2026

For reference the filters I am applying to the source connection is below. This works correctly before filters are applied.

 

{
"name": "Test Salesforce Source Connection",
"description": "This is a Source Connection for Salesforce with filters.",
"baseConnectionId": "2b714d1c-a800-4bdd-8085-361d3e86fb0a",
"data": {
"format": "tabular"
},
"params": {
"tableName": "Contact",
"columns": [
{
"name": "FirstName",
"type": "string",
"xdm": {
"type": "string"
}
},
{
"name": "LastModifiedDate",
"type": "string",
"xdm": {
"type": "string",
"format": "date-time"
}
}
],
"filters": {
"type": "PQL",
"format": "pql/json",
"value": {
"nodeType": "fnApply",
"fnName": "like",
"params": [
{
"nodeType": "fieldLookup",
"fieldName": "FirstName"
},
{
"nodeType": "literal",
"value": "Ell%"
}
]
}
}
},
"connectionSpec": {
"id": "cfc0fee1-7dc0-40ef-b73e-d8b134c436f5",
"version": "1.0"
}
}