|
|||
NRAO Home > CASA > CASA Toolkit Reference Manual |
|
table.addcols - Function
3.2.1 !!!REQUIRES COLUMN DESCRIPTION FUNCTIONS THAT HAVE NOT
BEEN IMPLEMENTED!!! add one or more columns
Description
Columns can be added to a table that was opened nomodify=False. The new
columns will be filled with a default value (0 or blank).
!!!THESE COLUMN DESCRIPTION FUNCTIONS HAVE NOT BEEN
IMPLEMENTED!!!
For each column to be added a column description has to be setup using
function tablecreatescalarcoldesc or tablecreatearraycoldesc. When multiple
columns are used, they have to be combined in a single record using
tablecreatedesc.
It is possible to specify data manager info in order to define a data manager
(storage manager or virtual column engine) for the columns to be added.
Arguments
Inputs |
| ||
desc |
| Description of one or more columns
| |
| allowed: | record | |
| Default: | ||
dminfo |
| Optional description data manager to use
| |
| allowed: | record |
|
| Default: |
|
|
bool
Example
!!!REQUIRES COLUMN DESCRIPTION FUNCTIONS THAT HAVE NOT BEEN IMPLEMENTED!!!
tb.open("mytable", nomodify=False)
dc3=tablecreatescalarcoldesc(’C3’, ’a’)
dc4=tablecreatescalarcoldesc(’C4’, as_float(0))
dc5=tablecreatearraycoldesc(’C5’, as_double(0), 2, [10,20])
tb.addcols(dc3)
# True
tb.addcols(tablecreatedesc(dc4, dc5))
# True
A single column can be added as such, but multiple columns have
to be combined.
__________________________________________________________________
More information about CASA may be found at the
CASA web page
Copyright © 2016 Associated Universities Inc., Washington, D.C.
This code is available under the terms of the GNU General Public Lincense
Home |
Contact Us |
Directories |
Site Map |
Help |
Privacy Policy |
Search