25.09.2015 Views

Teradata Parallel Data Pump

Teradata Parallel Data Pump Reference - Teradata Developer ...

Teradata Parallel Data Pump Reference - Teradata Developer ...

SHOW MORE
SHOW LESS
  • No tags were found...

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Appendix C: INMOD and Notify Exit Routine Examples<br />

Sample Notify Exit Routine<br />

{<br />

int rtn=0;<br />

int i=0;<br />

if (count < 50000)<br />

{<br />

a->buf.seqno = count;<br />

count++;<br />

for (i=0; ibuf.body[i] = 'X';<br />

a->buf.body[75] = '\0';<br />

}<br />

a->len=80;<br />

a->code=0;<br />

rtn=1;<br />

}<br />

else<br />

{<br />

printf("=== EOF ===\n");<br />

a->code=99;<br />

a->len=0;<br />

};<br />

return(rtn);<br />

Sample Notify Exit Routine<br />

The following is the listing of tldnfyxt.c, the sample notify exit routine that is provided with<br />

<strong>Teradata</strong> T<strong>Pump</strong> software.<br />

/*********************************************************************<br />

* *<br />

* tldnfyxt.c - Sample Notify Exit for Tpump. *<br />

* *<br />

* Copyright 1997-2009 <strong>Teradata</strong> Corporation. *<br />

* ALL RIGHTS RESERVED. *<br />

* <strong>Teradata</strong> Corporation CONFIDENTIAL AND TRADE SECRET *<br />

* *<br />

* This copyrighted material is the Confidential, Unpublished *<br />

* Property of the <strong>Teradata</strong> Corporation. This copyright notice and *<br />

* any other copyright notices included in machine readable *<br />

* copies must be reproduced on all authorized copies. *<br />

* *<br />

* *<br />

* Purpose - This is a sample notify exit for Tpump . *<br />

* *<br />

* Execute - Build Notify on a Unix system *<br />

* compile and link into shared object *<br />

* cc -G tldnfyxt.c - o libtldnfyxt.so *<br />

* - Build Notify on a Win32 system *<br />

* compile and link into dynamic link library *<br />

* cl /DWIN32 /LD tldnfyxt.c *<br />

* - Build Notify on AIX system *<br />

* cc -c -brtl -qalign=packed tldnfyxt.c *<br />

* ld -G -e_dynamn -bE:export_dynamn.txt tldnfyxt.o *<br />

* -o libtldnfyxt.so -lm -lc *<br />

* where export_dynamn.txt conaints the symbol "_dynamn"*<br />

* - Build Notify on Linux system *<br />

250 <strong>Teradata</strong> <strong>Parallel</strong> <strong>Data</strong> <strong>Pump</strong> Reference

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!