Running the Apex Data Loader on a Mac

Even though the Apex Data Loader is written in Java it doesn’t work on a Mac for two main reasons:

  • It is packaged in a Windows-only installer
  • Instead of using Swing for its GUI that does not require any platform-specific code to be included in the application it uses SWT that does require platform-specific code

The first problem can be worked around by installing on a Windows machine first and then copying the installation across to the Mac.

The second problem can be worked around using these steps (assuming you have a working copy of the Eclipse IDE on your Mac perhaps to make use of the Force IDE):

  • Copy the files that start org.eclipse.swt (e.g. org.eclipse.swt_3.6.1.v3655c.jar and org.eclipse.swt.cocoa.macosx.x86_64_3.6.1.v3655c.jar) from eclipse/plugins to the directory that contains DataLoader.jar (that you copied across from Windows).
  • Use this command-line (using the file names from the previous step) to run the DataLoader:
    java -Dsalesforce.config.dir=conf -XstartOnFirstThread -cp org.eclipse.swt_3.6.1.v3655c.jar:org.eclipse.swt.cocoa.macosx.x86_64_3.6.1.v3655c.jar:DataLoader.jar com.salesforce.dataloader.process.DataLoaderRunner

The -D argument specifies the location of the configuration files, the -X argument appears to be required for this version of SWT to work, the -cp argument gives priority to the Mac version of the SWT classes ahead of the Windows versions included in DataLoader.jar and the last argument is the name of the class that launches the GUI.

If you choose to run the data loader like this obviously Salesforce will not support you and you should be cautious and check your results carefully. Also consider using LexiLoader – see comments below.


5 thoughts on “Running the Apex Data Loader on a Mac

  1. I was a bit concerned that the LexiLoader is a few versions behind the current API but having said that I’m not aware of any changes that would cause problems. So if LexiLoader is working fine stick with that – its a lot less trouble to get running.

    Obviously what we would all like is for an official salesforce Mac version…

  2. Thanks! This saved me some pain, because LexiLoader required OS X 10.6. DataLoader.jar should be bundled in the eclipse plugin.

  3. I’m having trouble using Lexiloader via a secure proxy gateway.
    I need to add a cert file to the cacert file (which is easy to do with the Windows bulk loader) but I can’t seem to find the cacert file with Lexiloader.
    Anyone have any ideas?

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s