DTW_TB_APPENDROW

AIX HP-UX Linux OS/2 OS/390 OS/400 PTX SUN Win NT
X X
X X X X X X

Purpose

Adds one or more rows to the end of a Net.Data table.

Format

@DTW_TB_APPENDROW(table, rows)

Parameters

Table 120. DTW_TB_APPENDROW Parameters
Data Type Parameter Use Description
table table INOUT The macro table variable for which rows are appended.
integer rows IN The number of rows to append to table.

Return Codes

Table 121. DTW_TB_APPENDROW Return Codes
Return Code Explanation
-1001 The server could not process a Net.Data request to allocate memory.
1001 An input parameter contained a NULL value.
1003 An incorrect number of parameters were passed on a function call.
1004 A parameter passed on a function call, required to be a Net.Data macro table variable, was of a different variable type.
1005 A parameter passed on a function call, required to be a string variable, was of a different variable type.
1007 A parameter contains a value which is not valid.
1008 A parameter is outside of table bounds.
1010 Data was written to the table until it was full, and the remainder of the data was discarded.

Usage Notes

  1. The number of columns in the table must be set before calling DTW_TB_APPENDROW(). You can set the number of columns with the DTW_TB_SETCOLS() or DTW_TB_INSERTCOL() functions, or by passing the table to a language environment to be set.
  2. You can assign values to the new rows with the DTW_TB_SETV() function after rows are appended to the table, or pass the table to a language environment for processing.
  3. If there is a limit on the total number of rows allowed in the table, and the number of rows to be appended can cause the limit to be exceeded, an error is returned to the caller.

Examples

Example 1: Appends ten rows to the table

%DEFINE myTable = %TABLE
 
@DTW_TB_APPENDROW(myTable, "10")
 


[ Top of Page | Previous Page | Next Page | Index ]