# ADO Dataset Iterator hangs when called via Task Scheduler?

**URL:** <https://www.finalbuilder.com/forums/t/ado-dataset-iterator-hangs-when-called-via-task-scheduler/4570>\
**Category:** Discussion\
**Created:** [June 30, 2014, 5:58am UTC](https://www.finalbuilder.com/forums/t/ado-dataset-iterator-hangs-when-called-via-task-scheduler/4570 "2014-06-30T05:58:37Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![jonathanmeltzer](https://www.finalbuilder.com/forums/letter_avatar_proxy/v4/letter/j/34f0e0/32.png) [@jonathanmeltzer](https://www.finalbuilder.com/forums/u/jonathanmeltzer)\
**Post date:** [June 30, 2014, 5:58am UTC](https://www.finalbuilder.com/forums/t/ado-dataset-iterator-hangs-when-called-via-task-scheduler/4570/1 "2014-06-30T05:58:37Z")

</div>

I have gotten good answers from here so far, so here is another issue I have run into:  
  
I have an Automise project that calls the ADO Iterator. &nbsp;If I run the project within Automise, it runs fine. &nbsp;If I run it from a command line using ATCMD, it runs fine. &nbsp;If I run the same command line from the Task Scheduler after using the scheduler to create the task, it seems that the project hangs on the ADO Iterator step. &nbsp;The iterator, at the moment, should return 0 rows and move to the next step in the project. &nbsp;However, when I run the scheduled task, the task is still running after 20 minutes (from a command line, the whole project ends successfully in 3 seconds), and a look at the log seems to indicate that the ADO Iterator step starts but does not finish. &nbsp;I have to end the scheduled task and THEN kill the ATCMD process in Task Manager to get it to stop.  
  
The iterator itself is set up with the correct login/pwd to hit the database (as evidenced by other runs), and the login that is set up to run the scheduled task has permissions to run ATCMD.exe. &nbsp;Are there special permissions within the ADO Iterator or project setup that are needed to make the ADO Iterator run from within a scheduled task?  
  
Thanks,  
  
Jonathan

---

<div class="post-metadata">

**Author:** ![jonathanmeltzer](https://www.finalbuilder.com/forums/letter_avatar_proxy/v4/letter/j/34f0e0/32.png) [@jonathanmeltzer](https://www.finalbuilder.com/forums/u/jonathanmeltzer)\
**Post date:** [June 30, 2014, 8:53am UTC](https://www.finalbuilder.com/forums/t/ado-dataset-iterator-hangs-when-called-via-task-scheduler/4570/2 "2014-06-30T08:53:16Z")

</div>

OK, I have figured out that it is not the ADO Dataset Iterator. It is the program I am calling AFTER the ADO Dataset Iterator. I will start a new thread on that, and this one can be deleted.

---

<div class="post-metadata">

**Author:** ![nevar](https://www.finalbuilder.com/forums/letter_avatar_proxy/v4/letter/n/c4cdca/32.png) [@nevar](https://www.finalbuilder.com/forums/u/nevar)\
**Post date:** [July 1, 2014, 1:28am UTC](https://www.finalbuilder.com/forums/t/ado-dataset-iterator-hangs-when-called-via-task-scheduler/4570/3 "2014-07-01T01:28:40Z")

</div>

Hi Jonathan,   
  
 Apologies for not seeing this post earlier. I will take a look at your new post.
