Dev Space

Customize and extend the power of Alteryx with SDKs, APIs, custom tools, and more.
SOLVED

Salesforce Input Connector - Selecting Deleted Records

mpurdy
8 - Asteroid

 

I was wondering if it was possible to select deleted records using the Salesforce Input Connector? Thanks in advance for any help that you can provide.

31 REPLIES 31
ritutyagi2104
7 - Meteor

With Alteryx 11.5, way in which SalesForce input connector gets the data is through java file. Backend macro has become obsolete(deprecated) with new version.  With the new version of salesforce input connector, I have changed the piece of code in java file from " url = url + '/services/data/v'+apiVersion+'.0/query/' " to "  url = url + '/services/data/v'+apiVersion+'.0/queryAll/' ".

This works very well with alteryx designer but I get an error when I run my workflow from gallery. Error message is as seen in the image below. Could you please suggest how to resolve this error.Error_From _Gallery.jpg

mpurdy
8 - Asteroid

The instructions for the .js file are also listed in this conversation thread. You need to make a copy of the "SalesForceInput" directory, update the names of the files and the references in them to the new names. Then, as Neil said, you need to update the "query" to "queryall" in Salesforce.js:

 

I believe the relevant line of code that you're looking for is line  274 in the Salesforce.js file:

url = url + '/services/data/v'+apiVersion+'.0/query/';

 

mpurdy
8 - Asteroid

Sorry I have not used Gallery or Server so cannot comment on what you need to do to fix.

I would recommend creating a copy rather than editing the existing Salesforce Input tool though.

ritutyagi2104
7 - Meteor

Yes, I have followed steps to copy the "SalesForceInput" & Renamed it to "SalesForceInput - Queryall". I have changed piece of code in java file & have also renamed "SalesForceInput - Config" to "SalesForceInput - QueryallConfig". After this I see a new salesforce input connector in alteryx designer using which I am able to fetch deleted ids. However when I publish this to gallery & run the workflow from gallery I get error "Unable to resolve plugin HTML".

Do I need to rename any other folder inside the new folder(SalesForceInput - Queryall) which I created? I am just trying to understand why it doesn't work from gallery.

ritutyagi2104
7 - Meteor

@NeilR : Do you think of any reason why it doesn't work from gallery? I get the error "Unable to resolve plugin HTML 'SalesForceInputQueryAll\SalesforceInputEngine.html" from gallery. Do I need to apply any other setting ?

NeilR
Alteryx Alumni (Retired)

Because it is a custom plugin, and not a macro, publishing to the server doesn't automatically upload the custom tool. You'll need to install your new SalesForceInputQueryAll tool onto your server by copying the SalesForceInputQueryAll folder into the bin\HtmlPlugins folder within the Alteryx install on the server.

ritutyagi2104
7 - Meteor

I have already done this on server. But this doesn't help me. I keep getting the error.

NeilR
Alteryx Alumni (Retired)

Designer needs to be restarted after a custom plugin has been installed in order to recognize the new tool. So I imagine you'd also need to restart the Alteryx service on the server. Have you tried that?

ritutyagi2104
7 - Meteor

Yes Neil. I restarted alteryx designer after doing all the required steps on server. I also tried executing the workflow from designer on server. This works well. I only get the error from gallery. Any other suggestions due to which this might be happening?

NeilR
Alteryx Alumni (Retired)

I just went through the entire process and am unable to reproduce your error. Would you like to do a screenshare next week so I can try to help troubleshoot?