Think. Build. Salesforce Solutions.

Salesforce Consulting Services across Salesforce Clouds & Across App Lifecycles


Scheduling of data loader through command line

By |2020-07-15T06:20:53+00:00February 2nd, 2016|Tags: , , , |

Data loader is a tool provided by the salesforce so that we can perform various functions through it. The functions could be insert, update, delete, export, export all, upsert. This is a migration tool which is used to migrate data more than 50,000 in number, but a drawback of it is that it cannot scheduled.

Thus to overcome this drawback we make use of dataloader through command line interface which is scheduled with task manager.
The most important part of setting up Command Line Data loader is to generate the encrypted password using utility provided by the Data Loader.
C:\Program Files (x86)\\Data Loader\bin

schedule data loader salesforce

Before we start with the steps we need to create a folder (with any name, I used dataloader) which should have files with names.

1) Key.txt
2) Encrypted.txt
3) Success.csv
4) Errors.csv
5) AccountInsertMap.sdl or with csv extension.


Create Encryption Key
1. Open a command prompt.
2. In the cmd enter cd\ to navigate to the root directory of the drive where the dataloader is installed.
3. Enter to the bin through this command.
Cd C:\Program Files(x86)\\Apex Data Loader 22.0\bin
4. Generate an encryption Key
Encrypt.bat “g <seedtext>
Replace seedtext with any string.

schedule data loader salesforce
Step 2

Create an encrypted password.
In the same command prompt you have the following command:
Encrypt.bat <password> <filepath>\ key.txt
Replace with the password with which the dataloader login to salesforce and replace the file path with the key.txt path.

data loader scheduler salesforce
Copy the encrypted password that is generated by the command prompt. We will discuss this later.

Step 3

Create a mapping file with name accountInsertMap.sdl or a CSV file. The data is inserted so that the left-hand side data is equal to the destination field on the right-hand side.

#Mapping values
#Thu May 26 16:19:33 GMT 2011

The accountInsertMap.csv

data loader command line
Step 4

Create configuration file
Contains all the information the data loader needs to perform. Each bean of the config file performs an individual function such as insert, delete, update, etc. We perform an export from the following file.

Parameters for Process-config.xml:

Sfdc .endpoint:-Enter the URL of the Salesforce instance for your organization, for example
sfdc.username:-Enter the username with which your login to dataloader.
Sfdc.password: -Enter the password encrypted password which you create in step 2.
DataAccess.Name: -Enter the path and file name of the data file that contains the Accounts that you want to import.
The process-con file should be present in the dataloader folder.

schedule data loader salesforce
Step 5

1) Copy the following data to the filename accountInsert.csv. This is the account data which can be imported into the organization. You can have your own values.

Name, Number of Employees, Industry
Dickenson plc, 120, Consulting
Gene Point, 265, Biotechnology
Express Logistics and Transport, 12300, Transportation
Grand Hotels & Resorts Ltd, 5600, Hospitality2)In the command prompt window, we have the following command.
Process.bat <path to process-con.xml> process name

salesforce data loader cli
Note: – Provide the path to process-con.xml and in the process provide the name of the process name.

In our case, the process name will be insertAccounts as is present in the process-con.xml file.
<property name=”name” value=”insertAccounts”/>After the process runs the command prompt enter the success and error messages.
You can also check with the log files with the names success.csv and error.csv
The execution of the command also creates a log file, as the path needs to be given where the log file need to be created.
<entry key=”sfdc.debugMessagesFile” value=”C:\Users\Desktop\data loader\log\accountInsertSoaptrace.log”/>

Now another step is quite essential to schedule the command line dataloader, for this we require a bat file named as process.bat. This bat file contains path till bin and the path for the process-con.xml
This bat file should be present in the dataloader folder.

schedule data loader salesforce
Steps of scheduling dataloader through windows:

Click on start->control panel->System and security->Administrative tools->Task scheduler.

data loader scheduler salesforce
1) Click on create the task in actions.
2) Provide the name of the scheduled task.
3) Set up trigger timings as required to schedule the data loader jobs.
4) Set up the action with action type as Start Program and add process.bat file.
5) Save the task.
The scheduler will run the data loader processes as per the trigger time set in the windows scheduler task. This is how we schedule a data loader through command-line interface.


  1. albertson July 31, 2020 at 8:48 pm - Reply

    This is a great blog.

    • Mirketa Inc August 12, 2020 at 8:36 am - Reply

      Thanks, Albert

  2. Thomas Lawrence August 7, 2020 at 2:30 am - Reply

    I am really grateful to the holder of this web page who has shared this wonderful paragraph at

    • Mirketa Inc August 12, 2020 at 8:37 am - Reply

      You are very welcome

  3. Tiffany Tryon August 12, 2020 at 6:18 am - Reply

    I’m extremely impressed with your writing skills as well as
    with the layout on your blog. Is this a paid theme or did you customize it yourself?
    Either way keep up the excellent quality writing, it’s rare to see a nice blog like
    this one today.

    • Mirketa Inc August 12, 2020 at 8:34 am - Reply

      Thanks for the feedback

  4. Innano August 13, 2020 at 10:36 am - Reply

    I love reading your site.

    • Mirketa Inc September 2, 2020 at 6:43 am - Reply

      We appreciate that, Innano. Thank You!

  5. Anne September 14, 2020 at 7:52 am - Reply

    What’s up it’s me, I am also visiting this website regularly, this web site is in fact nice and the people are actually sharing pleasant thoughts.

  6. Natisha September 14, 2020 at 8:18 am - Reply

    Hello, my loved one! I wish to say that this post is amazing, nice written and include almost all important infos. I’d like to look more posts like this.

  7. Azucena September 14, 2020 at 8:19 am - Reply

    Hey! Quick question that’s totally off-topic.

    Do you know how to make your site mobile friendly? My site looks weird when viewing from my iPhone 4. I’m trying to find a theme or plugin that might be able to resolve this problem. If you have any recommendations, please share. Thank you!

  8. Christoper September 14, 2020 at 8:22 am - Reply

    Excellent site you’ve got here.. It’s hard to find high-quality writing like yours nowadays.
    I really appreciate people like you! Take care!!

  9. Floyd Yeager September 14, 2020 at 9:04 am - Reply

    Informative article, totally what I wanted to find.

  10. Kandis September 14, 2020 at 11:24 am - Reply

    Oh my goodness! Incredible article dude! Many thanks,

  11. 个人包裹快递 September 14, 2020 at 5:52 pm - Reply

    I do consider all of the ideas you have presented in your post.

    They are very convincing and will certainly work.
    Thank you for the post.

  12. Manuela September 14, 2020 at 7:50 pm - Reply

    I like the helpful information you provide in your articles.

    I will bookmark your blog and check again here frequently.
    I am quite certain I will learn plenty of new stuff right here! Good luck for the next!

  13. Maisie September 14, 2020 at 8:13 pm - Reply

    I really like your blog.. very nice colors & theme.

    Did you create this website yourself or did you hire someone to do it for you? Plz, reply as I’m looking to construct my own blog and would like to find out where u got this from appreciate it

  14. Luke September 14, 2020 at 8:56 pm - Reply

    Excellent items from you, man. I have take into account your stuff previous to and you are simply too excellent.
    I actually like what you’ve obtained here, certainly like what you are saying and the way in which you are
    saying it.
    You’re making it enjoyable and you continue to take care of to stay it sensible. I can’t wait to learn much more from you. That is really a tremendous website.

  15. Erma September 14, 2020 at 11:35 pm - Reply

    Hello to all, how is the whole thing, I think every one is getting more from this site, and your views are fastidious for new users.

  16. Bryce September 15, 2020 at 12:54 am - Reply

    This website definitely has all of the info I wanted about this subject and didn’t know who to ask.

  17. Maryann September 15, 2020 at 2:24 am - Reply

    Thanks for any other great article. Where else may anybody get that kind of information in such a perfect manner of writing?

  18. Isiah September 15, 2020 at 3:15 am - Reply

    Greetings! Quick question that’s totally off-topic. Do you know how to make your site mobile friendly? My website looks weird when viewing from my iPhone.
    I’m trying to find a theme or plugin that might be able to resolve this issue. If you have any recommendations, please share.
    With thanks!

  19. Wiley September 15, 2020 at 3:59 am - Reply

    Wow, this post is nice, my sister is analyzing these things, therefore I am going to let know her.

  20. Kristy September 15, 2020 at 4:35 am - Reply

    This paragraph provides clear idea for the new visitors of blogging, that truly how to do running a blog.

  21. Melvina September 15, 2020 at 6:15 am - Reply

    Normally I don’t learn article on blogs, but I would like to say that this write-up very pressured me to take a look at and do it!
    Your writing style has been surprised me. Thanks, very nice post.

  22. Donnie September 15, 2020 at 7:13 am - Reply

    Hi, I do believe this is an excellent blog.
    I stumbled upon it 😉

  23. Alvaro September 15, 2020 at 9:31 am - Reply

    Hello, yes this article is actually good and I have learned lot of things from it about blogging.

  24. Katrice September 15, 2020 at 9:51 am - Reply

    Everything is very open with a clear explanation of the challenges. It was truly informative. Your site is extremely helpful. Many thanks for sharing!

  25. Pasquale September 15, 2020 at 10:39 am - Reply

    Currently, it looks like Drupal is the best blogging platform available right now. (from what I’ve read) Is that what you are using on your blog?

  26. Freda September 15, 2020 at 10:50 am - Reply

    whoah, this blog is fantastic I really like studying your posts. Keep up the great work! You recognize a lot of people are searching around for this information, you can help them greatly.

  27. Hannah Brookes September 15, 2020 at 10:56 am - Reply

    Hi, I check your blogs like every week. Your humoristic style is awesome, keep up the good work!

  28. Caruther Ford September 15, 2020 at 11:10 am - Reply

    Wonderful website. Plenty of helpful info here. I am sending it to a few pals and additionally sharing in delicious. And of course, thanks!

  29. Lukas Connolly September 20, 2020 at 10:01 am - Reply

    I believe that is among the so much significant info for me.
    And I am happy to read your article.
    D. Good task, cheers

  30. Jamal Carvalho September 20, 2020 at 12:29 pm - Reply

    Very shortly this website will be famous among all blogging people, due to it’s pleasant content

Leave A Comment