The new ADF/Synapse connector to Salesforce no longer supports QueryAll to query deleted records in Salesforce. How can this be done?

Kevin Chadney 15 Reputation points
2024-02-28T21:15:09.6433333+00:00

Hi, The previous version of the ADF Salesforce connector (https://learn.microsoft.com/en-us/azure/data-factory/connector-salesforce-legacy?tabs=data-factory) supported querying deleted records in Salesforce:

User's image

But the new version (https://learn.microsoft.com/en-us/azure/data-factory/connector-salesforce?tabs=data-factory) does not appear support this option.

Is there a way to queryAll using the new connector, or to continue to use the legacy connector for new linked services. This functionality is crucial to my application. Thanks, Kevin

Azure Synapse Analytics
Azure Synapse Analytics
An Azure analytics service that brings together data integration, enterprise data warehousing, and big data analytics. Previously known as Azure SQL Data Warehouse.
5,157 questions
Azure Data Factory
Azure Data Factory
An Azure service for ingesting, preparing, and transforming data at scale.
11,183 questions
{count} vote

3 answers

Sort by: Most helpful
  1. Kevin Chadney 15 Reputation points
    2024-04-24T15:04:22.4766667+00:00

    This function has been added which replicates the QueryAll functionality:

    User's image

    2 people found this answer helpful.

  2. Manish Lagisetty 0 Reputation points
    2025-01-16T16:37:58.17+00:00

    Microsoft has missed to add drop down in GUI side but we can enable this feature from code wise, In adf after creating pipeline, open as script add this line
    , "includeDeletedObjects": True

    then it will pull all deleted data also.

    "activities":[

    {
    
        "name": "CopyFromSalesforce",
    
        "type": "Copy",
    
        "inputs": [
    
            {
    
                "referenceName": "<Salesforce input dataset name>",
    
                "type": "DatasetReference"
    
            }
    
        ],
    
        "outputs": [
    
            {
    
                "referenceName": "<output dataset name>",
    
                "type": "DatasetReference"
    
            }
    
        ],
    
        "typeProperties": {
    
            "source": {
    
                "type": "SalesforceV2Source",
    
                "query": "SELECT Col_Currency__c, Col_Date__c, Col_Email__c FROM AllDataType__c",
    
                **"includeDeletedObjects": True -- Add this code** 
    
            },
    
            "sink": {
    
                "type": "<sink type>"
    
            }
    
        }
    
    }
    

    ]

    0 comments No comments

  3. Vincenzo Dell'Oste 0 Reputation points
    2025-01-30T11:17:27.4833333+00:00

    I do still have a problem, the check box is clicked, but deleted records are not downloaded.

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.