17.00 - Allocate Storage - Parallel Transporter

Teradata® Parallel Transporter Operator Programmer Guide

prodname
Parallel Transporter
vrm_release
17.00
created_date
June 2020
category
Programming Reference
featnum
B035-2435-220K

Purpose

Allocate Storage is the service function that allocates Teradata PT storage for the operator.

Structure

#include <pxoper.h>
PXSTC_Code PX_AllocateStorage(PX_OperatorHandle  operator,
   PX_Length  storageSize,
   PX_Addr *  storageAddr);

where the following is true:

Parameter Function Specification
operator input Instance of the operator for which the storage is to be allocated.
storageSize input Amount of storage you want to allocate to the named operator.
storageAddr output Pointer to the address of the allocated storage.

Return Codes

The following Allocate Storage function status codes are defined by the Teradata PT operator interface.

Status Code Signifies
PXSTC_InvalidArgument One or more bad input arguments.
PXSTC_BadHandle An undefined object handle.
PXSTC_NotEnough Either:
  • Not enough storage can be allocated
  • The requested storage size is too large
PXSTC_Success Successful access to the object attribute.

Usage Notes

Consider the following when using the Allocate Storage function.

Topic Usage Note
Status If the function status is PXSTC_Success, the storage address will be stored in the location indicated by the storageAddr parameter. See also the Free Storage function.