Previous Page | Next Page

Data Set Options for Relational Databases

TPT_APPL_PHASE= Data Set Option



Specifies whether a load process that is being restarted has failed in the application phase.
Default value: NO
Valid in: PROC steps (when accessing DBMS data using SAS/ACCESS software)
DBMS support: Teradata

Syntax
Syntax Description
Details
Examples
See Also

Syntax

TPT_APPL_PHASE=YES | NO

Syntax Description

YES

specifies that the Fastload or MultiLoad run that is being restarted has failed in the application phase. This is valid only when SAS uses the TPT API.

NO

specifies that the load process that is being restarted has not failed in the application phase.


Details

To use this option, you must first set TPT=YES.

SAS can restart from checkpoints any Fastload, MultiLoad, and Multi-Statement insert that is run using the TPT API. The restart procedure varies: It depends on whether checkpoints were recorded and in which phase the step failed during the load process. Teradata loads data in two phases: the acquisition phase and the application phase. In the acquisition phase, data transfers from SAS to Teradata. After this phase, SAS has no more data to transfer to Teradata. If failure occurs after this phase, set TPT_APPL_PHASE=YES in the restart step to indicate that restart is in the application phase. (Multi-Statement insert does not have an application phase and so need not be restarted if it fails after the acquisition phase.)

Use OBS=1 for the source data set when restart occurs in the application phase. When SAS encounters TPT_RESTART=YES and TPT_APPL_PHASE=YES, it initiates restart in the application phase. No data from the source data set is actually sent. If you use OBS=1 for the source data set, the SAS step completes as soon as it reads the first record. (It actually throws away the record because SAS already sent all data to Teradata for loading.)


Examples

Here is a sample SAS program that failed after the acquisition phase.

libname x teradata user=testuser pw=testpw;
data x.test(MULTILOAD=YES TPT=YES CHECKPOINT=7);
do i=1 to 20;
output;
end;
run;

ERROR: Teradata connection:  Failure occurred after the acquisition phase. 
Restart outside of SAS using checkpoint data 14.

Set TPT_APPL_PHASE=YES to restart when failure occurs in the application phase because SAS has already sent all data to Teradata.

proc append base=x.test(MULTILOAD=YES TPT_RESTART=YES 
    TPT_CHECKPOINT_DATA=14 TPT_APPL_PHASE=YES) data=test(obs=1);
run;


See Also

Maximizing Teradata Load Performance

Using the TPT API

BULKLOAD= LIBNAME Option

BULKLOAD= Data Set Option

MULTILOAD= Data Set Option

TPT= LIBNAME Option

TPT= Data Set Option

TPT_CHECKPOINT_DATA= Data Set Option

TPT_RESTART= Data Set Option

Previous Page | Next Page | Top of Page