I have written quite a few batch files which use db2cmd and this works fine. However, a few batch files are being scheduled within windows and do not need the CLP popup (they reporting to a file) so I am using db2clpex.exe instead which seems to work fine and the CLP doesn't appear. Here is a sample use:

echo CONNECT to mydb user me using 'mypassword' >> %0.ddl
echo SELECT * employees >> %0.ddl
echo TERMINATE >> %0.ddl

db2cmd /c db2 -f %0.dll (OR the following if scheduled)
db2clpex.exe /c db2 -f %0.dll (CLP window doesn't popup)

However, there is not much documentation on db2clpex so I have the following question.

- Is db2cmd and db2clpex pretty much interchangeable or are there special concerns relating to the use of db2clpex.exe?
- what is the actual difference between these to programs?