next up previous 264
Next: AST_ADDFRAME - Add a Frame to a FrameSet to define a new coordinate system
Up: AST Routine Descriptions
Previous: AST_SET - Set attribute values for an Object


AST_ADDCOLUMN - Add a new column definition to a table

Description:
Adds the definition of a new column to the supplied table. Initially, the column is empty. Values may be added subsequently using the methods of the KeyMap class.
Invocation:
CALL AST_ADDCOLUMN( THIS, NAME, TYPE, NDIM, DIMS, UNIT, STATUS )
Arguments:
THIS = INTEGER (Given)
Pointer to the Table.
NAME = CHARACTER $*$ ( $*$ ) (Given)
The column name. Trailing spaces are ignored (all other spaces are significant). The supplied string is converted to upper case.
TYPE = INTEGER (Given)
The data type associated with the column. See "Applicability:" below.
NDIM = INTEGER (Given)
The number of dimensions spanned by the values stored in a single cell of the column. Zero if the column holds scalar values.
DIMS( NDIM ) = INTEGER (Given)
An array holding the the lengths of each of the axes spanned by the values stored in a single cell of the column. Ignored if the column holds scalara values.
UNIT = CHARACTER $*$ ( $*$ ) (Given)
A string specifying the units of the column. Supply a blank string if the column is unitless.
STATUS = INTEGER (Given and Returned)
The global status.
Class Applicability:
Table
Tables can hold columns with any of the following data types - AST__INTTYPE (for integer), AST__SINTTYPE (for INTEGER$*$2), AST__BYTETYPE (for bytes), AST__DOUBLETYPE (for double precision floating point), AST__FLOATTYPE (for single precision floating point), AST__STRINGTYPE (for character string), AST__OBJECTTYPE (for AST Object pointer), AST__POINTERTYPE (for arbitrary C pointer) or AST__UNDEFTYPE (for undefined values created by AST_MAPPUTU).
FitsTable
FitsTables can hold columns with any of the following data types - AST__INTTYPE (for integer), AST__SINTTYPE (for INTEGER$*$2), AST__BYTETYPE (for bytes), AST__DOUBLETYPE (for double precision floating point), AST__FLOATTYPE (for single precision floating point), AST__STRINGTYPE (for character string).
Notes:
  • This routine returns without action if a column already exists in the Table with the supplied name and properties. However an error is reported if any of the properties differ.


next up previous 264
Next: AST_ADDFRAME - Add a Frame to a FrameSet to define a new coordinate system
Up: AST Routine Descriptions
Previous: AST_SET - Set attribute values for an Object

AST A Library for Handling World Coordinate Systems in Astronomy
Starlink User Note 210
R.F. Warren-Smith & D.S. Berry
24th May 2011
E-mail:ussc@star.rl.ac.uk

Copyright (C) 2009 Science \& Technology Facilities Council