There are two ways of running an XCOM transmission. You can either run it immediately (execute) or at a specified time (schedule). You can schedule a transmission for the current date and time and then it will be run as soon as there are sufficient resources available to run the transmission so this gives you better control of the transmission than using execute.
The problem is that the scheduled transmission is handled by the XCOM program and not by the job that triggered the transmission and therefore you cannot check the return code from that job to determine the success or otherwise of the transmission. At the time that the triggering step completes the file may not even have started to be sent.
The solution is the inquire option which is the third option that can be used along with execute and schedule. The difference is that inquire does not trigger a new transmission but rather inquires about an existing transmission. An inquire job will continue to run until either XCOM advises it that the file has been transmitted successfully or failed to be transmitted. The inquire job can also be set to time out and produce a transmission failure message if it has not been advised of a successful transmission within a specified time. You can therefore use the inquire option within XCOM to test for the successful completion of your scheduled transmission so your transmission job needs to contain two steps one to schedule the transmission and the other to inquire on it.
There are a couple of things to keep in mind when specifying a timeout value for the inquire step. The first is that the file will take a certain amount of time to be sent depending on the size of the file and the speed of the link. Depending on the load on the line there may also be a delay before the transmission can start. If the timeout value is too soon then the file transmission may not complete before that time is reached giving a failed response even though the file transmission actually goes on to complete successfully at a later time. You need to therefore allow sufficient time for the file transmission and any delays if this false failure result is not to be a frequent occurrence defeating the purpose of the inquire.
On the other hand, there may be a problem with the line so that the transmission is unable to start at all. As there is no problem with the transmission itself, XCOM will just hold onto the transmission so that it can be started after the line error is fixed. In this case unless you have someone constantly monitoring the line there will be no indication of any problem until the inquire step times out. For this reason you want to set a timeout value that is not too long or you will end up with long delays every time that you have a problem.
The timeout value needs to be set as a reasonable compromise between these two conditions. If the size of files transmitted across a single link vary dramatically in size then you may want to set the timeout value appropriate for the majority of the files while accepting that an occasional larger file will always exceed the time limit. Of course you may find a way of dynamically setting the timeout value depending on the size of each file but you will still then be faced with a long delay before you find out that there is a line error when you are trying to send a really large file.
This article written by Stephen Chapman, Felgall Pty Ltd.