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...

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

APPENDIX C<br />

INMOD and Notify Exit Routine<br />

Examples<br />

This appendix provides INMOD examples using C INMOD - UNIX<br />

These examples contain z/OS control statements.<br />

Workstation-based clients support only INMODs written in C; an example of this is also<br />

provided in this appendix.<br />

C INMOD - UNIX<br />

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

* *<br />

* TITLE: tpumpimd.c *<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 />

Notes:<br />

This program is for INMOD testing using C user exit routine.<br />

When this routine is activated it looks at the content of the<br />

function code passed (a->code) and depending on its value, it<br />

0) initializes, i.e., opens a file, etc...<br />

1) reads a record<br />

5) acknowledges "close inmod" request. The user exit routine<br />

must return "return code"(a->code) and "length" (a->len). You<br />

should send return code = zero when no errors occur and non-zero for<br />

an error. LOAD expects length = zero at the end of file. Then<br />

it sends "CLOSE INMOD" request. THE USER EXIT routine must<br />

explicitly return "return code" = ZERO to terminate the<br />

conversation.<br />

The following TPUMP control statements will work with this inmod:<br />

.LOGTABLE ;<br />

.LOGON ;<br />

DROP TABLE TABLE200;<br />

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

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

Saved successfully!

Ooh no, something went wrong!