How can I pull a list of the same query fields the DataLoader WebUI uses when you go to export each Salesforce data object to a CSV file? This list of query fields will be used in the DataLoader CLI as a way to perform automatic backups.

Previously tried attempts: ANT Migration Tool - Doesn't pull the exact same query fields that the DataLoader WebUI provides and causes automation issues as a result

  • What is the "DataLoader WebUI"? Are you referring to workbench.developerforce.com or dataloader.io or something else? – Mark Pond Jul 18 '18 at 19:57
  • That article only describes where to locate the DataLoader application download in an org. – Mark Pond Jul 18 '18 at 20:14
  • That's correct and that's the program I'm using. – xorLogic Jul 18 '18 at 20:25

Data Loader applies the Field-Level Security permissions of the running user. If you can see the field in Salesforce and you log in to Data Loader, it can see that field. If you can't see the field, neither can Data Loader. So there's not a single list - it's based on your individual permissions.

The Metadata API used by the Force.com Migration Tool can always see all fields.

I didn't realize you were using the Data Loader CLI, with which I have no experience. I don't know whether it has the capability in itself to pull a list of visible fields for you. You can do this using Workbench's REST Explorer, however, or directly calling the REST API in your scripts. Issue a GET request to

<your domain>/services/data/v43.0/sobjects/<sobject name>/describe

The "fields" key in the JSON response contains a list of maps, each of which contains the key "name". Those are the fields you can see. If you don't feel like parsing JSON to make this dynamic, you can just copy and paste the list of fields out of the Workbench UI.

An alternate approach to perform a regular backup is to use the Weekly Data Export service, which inherently can see everything and can also include attachments and files.

  • Thanks David Reed, but I'm only looking for a way to pull what DataLoader already sees because that's required when you use the DataLoader CLI to extract entire Salesforce objects to CSV format. The ANT Tool doesn't see everything that DataLoader sees and sometimes it sees more than what DataLoader sees. – xorLogic Jul 18 '18 at 19:22
  • I'm a little confused because that's the opposite of what you said in your question. Would you edit your question to add more detail about what you're trying to do and what does not work? – David Reed Jul 18 '18 at 19:23
  • Let me know if that helps. I can go into detailed specifics such as files I'm using, etc... – xorLogic Jul 18 '18 at 19:38
  • Ah, trying to avoid the Weekly Data Export service because I want the backup data itself to reside outside of the Salesforce environment – xorLogic Jul 18 '18 at 19:51

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.