Index: trunk/MagicSoft/Mars/datacenter/scripts/buildsequenceentries
===================================================================
--- trunk/MagicSoft/Mars/datacenter/scripts/buildsequenceentries	(revision 9047)
+++ trunk/MagicSoft/Mars/datacenter/scripts/buildsequenceentries	(revision 9054)
@@ -50,20 +50,12 @@
 
 # get todo list
-getdolist  >> $scriptlog 2>&1
-
-# retrieve dates from todofile
-dates=(`cat $todofile`)
-if [ "$dates" = "" ]
-then 
-   echo "nothing to do -> exit"  >> $scriptlog 2>&1
-   finish >> $scriptlog 2>&1
-fi
-echo "dates: "${dates[@]} >> $scriptlog 2>&1
-rm -v $todofile >> $scriptlog 2>&1
+gettodo  >> $scriptlog 2>&1
 
 cd $mars
 
-for date in ${dates[@]}
-do 
+for (( s=0 ; s < $num ; s++ ))
+do
+   date=${primaries[$s+$s]}
+   telnum=${primaries[$s+$s+1]}
    echo "building sequence entries for date $date..." >> $scriptlog 2>&1
    printprocesslog "INFO build sequence entries for $date"
@@ -73,8 +65,7 @@
    buildsequentrieslog=$buildsequentriespath/buildsequenceentries-$date.log
 
-   primvar=$date
    setstatus "start" >> $scriptlog 2>&1
 
-   check1=`root -q -b $macrospath/buildsequenceentries.C+\("\"$date\""\,"\"$datapath\""\,"\"$sequpath\""\,1\,kFALSE\) | tee $buildsequentrieslog | intgrep`
+   check1=`root -q -b $macrospath/buildsequenceentries.C+\("\"$date\""\,"\"$datapath\""\,"\"$sequpath\""\,$telnum\,kFALSE\) | tee $buildsequentrieslog | intgrep`
 
    case $check1 in
