Once a Teradata PT driver task completes, the connection must be terminated. Do this with the Connection object’s Terminate method.
The Terminate method closes all sessions associated with the connection and ends the driver’s processing environment.
Your program should always call Terminate whenever any program fails prematurely, so that Teradata PT can do cleanup tasks such as releasing storage and logging off all DBS sessions. If your program cannot call Terminate and has stopped, you may be able to submit a restart job. If you submit a restart job and get errors, wait until the DBS logs off all orphan sessions (the default time is 20 minutes) and then submit the restart job again.