Please correct my script

Please correct my script if it any exceptional, since im calling other external script with in my script.

#!/bin/bash

FE1=TMM
DT1=/home/myHome/dated_1
REPORT=/home/otherHome/Report.sh

## Run the report for FE1 & DT1

cd /home/myHome
SERV_LST=/home/myHome/srvc-lst
echo "Welcome to other home"
echo "Running The Report for You NOW"
for i in `cat $SERV_LST`
do
$REPORT  $i -f {FE1} -d {DT1}
done
if [ $? -ne 0 ]
then
 echo " There is Some Issue"
fi
exit 1

Content of DT1

20110603
20110606
20110612
20110711
20110724
20110811

Content of SERV_LST

-a myServiceService -o myServiceBillCycleList
-a myServiceService -o myServiceCTypeInfo
-a myServiceService -o myServiceDTypeInfo
-a myServiceService -o myServiceHpptt
-a myServiceService -o myServiceLargeBan
-a myServiceService -o myServiceMarketInfo
-a myServiceService -o myServiceParameterValues
-a myServiceService -o myServiceSecurityInfo
-a myServiceService -o myServiceStaticIp
-a myServiceService -o myServiceTin
-a myResourceInfoService -o TMSAvailableNxx
-a myResourceInfoService -o TMSEnrollResourceHistoryList
-a myResourceInfoService     -o TMSEnrollTalkGroupList
-a TMSEnrollInfoService -o TMSAslAccount
-a TMSEnrollInfoService -o TMSEnrollAttributes
-a TMSEnrollInfoService -o TMSEnrollBasicInfo
-a TMSEnrollInfoService -o TMSEnrollSer
-a TMSUsageService -o TMSEnrollBilledU
-a TMSUsageService -o TMSEnrollUnbilledU
-a TMSUsageService -o TMSEnrollUnbilledUs
-a myTMSService -o AuthenticateUserLogin
-a myTMSService -o UpdateEPassword
-a myTMSService -o UpdateMailPasscode
-a myTMSService -o validateAccountPin
-a SmsPreference -o TMSSmsPrefeInfo
-a SmsPreference -o UpdateSmsPreferenceInfo
-a StatusCenterService -o TMSStatusCenterMessages
-a EnrollManagementService -o ManageEnrollServices
-a EnrollManagementService -o SetEnrollMarketingPreference
-a EnrollManagementService -o SubmitOrder
-a EnrollManagementService -o UpdateEnrollDetails

\

This script is needed to generate hundreds of reports, which is time consuming. The result im getting is nothing but a nested script usage, that means my script is having problem with usage parameter.

Nested Script Usage parameter is something like this:

./report.sh -a TMSServ -o updateTime -f XYZ -d DATE

you need to replace your for loop to while loop as below

Because i guess you need to pass the entire line to the external script ?
In this case, $i hold this value -a SmsPreference -o UpdateSmsPreferenceInfo

 
while read i 
do
$REPORT  $i -f ${FE1} -d ${DT1}
done < $SERV_LST

Result is different this time, I do receiving the result but its partial, since the script is not reading the DATE file, which contains the date for which the script should generate the report and also i values (-a) and (-o) as well.

while read i
do
$REPORT -f {FE1} -d {DT1}
done < $SERV_LST
$REPORT  $i -f ${FE1} -d ${DT1}

It's better to see?

I still see some error here, the ${DT1} is not getting the exposed, instead it showing something like this.

gzip: /logs/Server1/ConfigFiles/SAVED_TRANS_DATA/MIN_BY_MIN//home/myHome/dated_1//home/myHome/dated_1*_MinuteByMinute_APPLIDS_Data*.gz: No such file or directory

The highlighted one is the error instead it should use the dates mentioned in the above write up.

20110603
20110606
20110612
20110711
20110724

20110811

---------- Post updated at 02:32 AM ---------- Previous update was at 02:13 AM ----------

The script is unable to read the dates populated in DT1, because of which script not generating the reports for the dates mentioned in the input file.

You'll need two loops then.

while read i; do
  while read j; do
    ${REPORT} $i -f ${FE1} -d $j
  done < "${DT1}"
done < "${SERV_LST}"

But that'd read the dates file many times. Since you're using bash maybe just

dates=$(<"${DT1}")

while read i; do
  for date in $dates; do
    ${REPORT} $i -f ${FE1} -d $date
  done
done < "${SERV_LST}"