15.10 - C Notify Exit Parameters - MultiLoad

Teradata MultiLoad Reference

prodname
MultiLoad
vrm_release
15.10
category
Programming Reference
featnum
B035-2409-035K

C Notify Exit Parameters

Following is a C structure that describes the parameters passed to a notify exit routine. The pointer is a 32-bit value, and all long definitions are 32-bit unsigned.

typedef enum {
   NMEventInitialize     =  0,
   NMEventFileInmodOpen  =  1,
   NMEventPhaseIBegin    =  2,
   NMEventCheckPoint     =  3,
   NMEventPhaseIEnd      =  4,
   NMEventPhaseIIBegin   =  5,
   NMEventPhaseIIEnd     =  6,
   NMEventErrorTableI    =  7,
   NMEventErrorTableII   =  8,
   NMEventDBSRestart     =  9,
   NMEventCLIError       = 10,
   NMEventDBSError       = 11,
   NMEventExit           = 12,
   NMEventAmpsDown       = 21,
   NMEventImportBegin    = 22,
   NMEventImportEnd      = 23,
   NMEventDeleteInit     = 24,
   NMEventDeleteBegin    = 25,
   NMEventDeleteEnd      = 26,
   NMEventDeleteExit     = 27,
   NMEventPhaseIEnd64    = 28,   
   NMEventImportEnd64    = 29,   
   NMEventInitializeEON  = 30,  
   NMEventPhaseIBeginEON = 31,   
   NMEventCheckPoint64   = 32,   
   NMEventPhaseIIEnd64   = 33,  
   NMEventErrorTableI64  = 34,   
   NMEventErrorTableII64 = 35,   
   NMEventDeleteInitEON  = 36,   
   NMEventDeleteBeginEON = 37,   
   NMEventDeleteEnd64    = 38   
} NfyMLDEvent;
 
#define NOTIFYID_FASTLOAD      1
#define NOTIFYID_MULTILOAD     2
#define NOTIFYID_FASTEXPORT    3
#define NOTIFYID_BTEQ          4
#define NOTIFYID_TPUMP         5
 
#define MAXVERSIONIDLEN    32
#define MAXUTILITYNAMELEN  32
#define MAXUSERNAMELEN     64
#define MAXUSERSTRLEN      80
#define MAXTABLENAMELEN   128
#define MAXFILENAMELEN    256
#define MAXDBASENAMELEN    62          
#define MAXUINT64LEN       24       
 
 
typedef struct _MLNotifyExitParm {
   UInt32 Event;                      /* should be NfyMLDEvent values */
   union {
      struct {
         UInt32 VersionLen;
         char   VersionId[MAXVERSIONIDLEN];
         UInt32 UtilityId;
         UInt32 UtilityNameLen;
         char   UtilityName[MAXUTILITYNAMELEN];
         UInt32 UserNameLen;        
         char   UserName[MAXUSERNAMELEN];
         UInt32 UserStringLen; 
         char   UserString[MAXUSERSTRLEN];
      } Initialize;
      struct {
         UInt32 FileNameLen;
         char   FileOrInmodName[MAXFILENAMELEN];
         UInt32 ImportNo;
      } FileInmodOpen ;
      struct {
         UInt32 TableNameLen;
         char   TableName[MAXTABLENAMELEN];
         UInt32 TableNo;
         char   DBaseName[MAXDBASENAMELEN];  
      } PhaseIBegin;
      struct {
         UInt32 RecordCount;
      } CheckPoint;
      struct {
         UInt32 RecsRead;
         UInt32 RecsSkipped;
         UInt32 RecsRejected;
         UInt32 RecsSent;
      } PhaseIEnd ;
      struct {
         UInt32 dummy;
      } PhaseIIBegin;
      struct {
         UInt32 Inserts;
         UInt32 Updates;
         UInt32 Deletes;
         UInt32 TableNo;
      } PhaseIIEnd;
      struct {
         UInt32 Rows;
         UInt32 TableNo;
      } ErrorTableI;
      struct {
         UInt32 Rows;
         UInt32 TableNo;
      } ErrorTableII ;
      struct {
         UInt32 dummy;
      } DBSRestart;
      struct {
         UInt32 ErrorCode;
      } CLIError;
      struct {
         UInt32 ErrorCode;
      } DBSError;
      struct {
         UInt32 ReturnCode;
      } Exit;
      struct {
         UInt32 dummy;
      } AmpsDown;
      struct {
         UInt32 ImportNo;
      } ImportBegin ;
      struct {
         UInt32 RecsRead;
         UInt32 RecsSkipped;
         UInt32 RecsRejected;
         UInt32 RecsSent;
         UInt32 ImportNo;
      } ImportEnd ;
      struct {/* DR123961 */
         UInt32 VersionLen;
         char   VersionId[MAXVERSIONIDLEN];
         UInt32 UtilityId;
         UInt32 UtilityNameLen;
         char   UtilityName[MAXUTILITYNAMELEN];
         UInt32 UserNameLen;        
         char   UserName[MAXUSERNAMELEN];
         UInt32 UserStringLen; 
         char   UserString[MAXUSERSTRLEN];
      } DeleteInit;
      struct {
         UInt32 TableNameLen;
         char   TableName[MAXTABLENAMELEN];
         UInt32 TableNo;
         char   DBaseName[MAXDBASENAMELEN];  
      } DeleteBegin;
      struct {
         UInt32 Deletes;
         UInt32 TableNo;
      } DeleteEnd;
      struct {
         UInt32 ReturnCode;
      } DeleteExit;   
      struct {
         char RecsRead[MAXUINT64LEN];
         char RecsSkipped[MAXUINT64LEN];
         char RecsRejected[MAXUINT64LEN];
         char RecsSent[MAXUINT64LEN];
      } PhaseIEnd64 ;
      struct {
         char RecsRead[MAXUINT64LEN];
         char RecsSkipped[MAXUINT64LEN];
         char RecsRejected[MAXUINT64LEN];
         char RecsSent[MAXUINT64LEN];
         UInt32 ImportNo;
      } ImportEnd64 ;       
      struct {
         UInt32 VersionLen;
         char   VersionId[MAXVERSIONIDLEN];
         UInt32 UtilityId;
         UInt32 UtilityNameLen;
         char   UtilityName[MAXUTILITYNAMELEN];
         UInt32 UserNameLen;        
         char   *UserName;
         UInt32 UserStringLen; 
         char   *UserString;
      } InitializeEON;
      struct {
         UInt32 TableNameLen;
         char   *TableName;
         UInt32 TableNo;
         char   *DBaseName;  
      } PhaseIBeginEON;
      struct {
         char RecordCount[MAXUINT64LEN];
      } CheckPoint64;
      struct {
         char Inserts[MAXUINT64LEN];
         char Updates[MAXUINT64LEN];
         char Deletes[MAXUINT64LEN];
         UInt32 TableNo;
      } PhaseIIEnd64;
      struct {
         char Rows[MAXUINT64LEN];
         UInt32 TableNo;
      } ErrorTableI64;
      struct {
         char Rows[MAXUINT64LEN];
         UInt32 TableNo;
      } ErrorTableII64 ;
      struct {
         UInt32 VersionLen;
         char   VersionId[MAXVERSIONIDLEN];
         UInt32 UtilityId;
         UInt32 UtilityNameLen;
         char   UtilityName[MAXUTILITYNAMELEN];
         UInt32 UserNameLen;        
         char   *UserName;
         UInt32 UserStringLen; 
         char   *UserString;
      } DeleteInitEON;
      struct {
         UInt32 TableNameLen;
         char   *TableName;
         UInt32 TableNo;
         char   *DBaseName; 
      } DeleteBeginEON;
      struct {
         char Deletes[MAXUINT64LEN];
         UInt32 TableNo;
      } DeleteEnd64;
   } Vals;
} MLNotifyExitParm;
 
#ifdef I370                                           
#define  MLNfyExit MLNfEx                              
#endif                                             
 
 
#ifdef I370
extern long MLNfyExit(
#else
extern Int32 MLNfyExit(
#endif
 
 
#ifdef __STDC__                                
          MLNotifyExitParm *Parms
#endif                           
);