Tables Action Set: Syntax

Provides actions for accessing and managing data

update Action

Updates rows in a table.

CASL Syntax

table.update < result = results> < status= rc> /
set={{
value=" string",
* var=" variable-name"
}, {...}}
* table={
caslib=" string",
computedOnDemand=TRUE | FALSE,
computedVars={{
format=" string",
formattedLength= integer,
label=" string",
* name=" variable-name",
nfd= integer,
nfl= integer
}, {...}},
computedVarsProgram=" string",
groupBy={{
format=" string",
formattedLength= integer,
label=" string",
* name=" variable-name",
nfd= integer,
nfl= integer
}, {...}},
groupByMode="NOSORT" | "REDISTRIBUTE",
importOptions={ fileType="AUTO" | "BASESAS" | "CSV" | "DTA" | "ESP" | "EXCEL" | "FMT" | "HDAT" | "JMP" | "LASR" | "MVA" | "SPSS" | "XLS", fileType-specific-parameters},
* name=" table-name",
onDemand=TRUE | FALSE,
orderBy={{
format=" string",
formattedLength= integer,
label=" string",
* name=" variable-name",
nfd= integer,
nfl= integer
}, {...}},
singlePass=TRUE | FALSE,
vars={{
format=" string",
formattedLength= integer,
label=" string",
* name=" variable-name",
nfd= integer,
nfl= integer
}, {...}},
where=" where-expression"
}
;

Parameter Descriptions

set={{valueelement-1} <, {valueelement-2}, ...>}

specifies the variable name and the value to set. Use the where parameter to limit the updates to specific rows.

To simplify, you can specify only a value for the var parameter. In this case, the other parameters in the list use default values.

The valueelement value can be one or more of the following:
value="string"
* var="variable-name"
Aliasname

* table={castable}

specifies the settings to apply to an input table.

To simplify, you can specify only a value for the name parameter. In this case, the other parameters in the list use default values.

For more information about this common parameter, see castable.

Result Descriptions

rowsUpdated

The result is a 64-bit integer. You can access the value from results.rowsUpdated.

tableName

The result is a string. You can access the value from results.tableName.

update Action

Updates rows in a table.

Lua Syntax

results, info = s: table_update{
set={{
value=" string",
* var=" variable-name"
}, {...}},
* table={
caslib=" string",
computedOnDemand=true | false,
computedVars={{
format=" string",
formattedLength= integer,
label=" string",
* name=" variable-name",
nfd= integer,
nfl= integer
}, {...}},
computedVarsProgram=" string",
groupBy={{
format=" string",
formattedLength= integer,
label=" string",
* name=" variable-name",
nfd= integer,
nfl= integer
}, {...}},
groupByMode="NOSORT" | "REDISTRIBUTE",
importOptions={ fileType="AUTO" | "BASESAS" | "CSV" | "DTA" | "ESP" | "EXCEL" | "FMT" | "HDAT" | "JMP" | "LASR" | "MVA" | "SPSS" | "XLS", fileType-specific-parameters},
* name=" table-name",
onDemand=true | false,
orderBy={{
format=" string",
formattedLength= integer,
label=" string",
* name=" variable-name",
nfd= integer,
nfl= integer
}, {...}},
singlePass=true | false,
vars={{
format=" string",
formattedLength= integer,
label=" string",
* name=" variable-name",
nfd= integer,
nfl= integer
}, {...}},
where=" where-expression"
}
}

Parameter Descriptions

set={{valueelement-1} <, {valueelement-2}, ...>}

specifies the variable name and the value to set. Use the where parameter to limit the updates to specific rows.

To simplify, you can specify only a value for the var parameter. In this case, the other parameters in the list use default values.

The valueelement value can be one or more of the following:
value="string"
* var="variable-name"
Aliasname

* table={castable}

specifies the settings to apply to an input table.

To simplify, you can specify only a value for the name parameter. In this case, the other parameters in the list use default values.

For more information about this common parameter, see castable.

Result Descriptions

rowsUpdated

The result is a 64-bit integer. You can access the value from results.rowsUpdated.

tableName

The result is a string. You can access the value from results.tableName.

update Action

Updates rows in a table.

Python Syntax

results= s. table.update(
set=[{
" value":" string",
* " var":" variable-name"
}<, {...}>],
* table={
" caslib":" string",
" computedOnDemand":True | False,
" computedVars":[{
" format":" string",
" formattedLength": integer,
" label":" string",
* " name":" variable-name",
" nfd": integer,
" nfl": integer
}<, {...}>],
" computedVarsProgram":" string",
" groupBy":[{
" format":" string",
" formattedLength": integer,
" label":" string",
* " name":" variable-name",
" nfd": integer,
" nfl": integer
}<, {...}>],
" groupByMode":"NOSORT" | "REDISTRIBUTE",
" importOptions":{ fileType="AUTO" | "BASESAS" | "CSV" | "DTA" | "ESP" | "EXCEL" | "FMT" | "HDAT" | "JMP" | "LASR" | "MVA" | "SPSS" | "XLS", fileType-specific-parameters},
* " name":" table-name",
" onDemand":True | False,
" orderBy":[{
" format":" string",
" formattedLength": integer,
" label":" string",
* " name":" variable-name",
" nfd": integer,
" nfl": integer
}<, {...}>],
" singlePass":True | False,
" vars":[{
" format":" string",
" formattedLength": integer,
" label":" string",
* " name":" variable-name",
" nfd": integer,
" nfl": integer
}<, {...}>],
" where":" where-expression"
}
)

Parameter Descriptions

set=[{valueelement-1} <, {valueelement-2}, ...>]

specifies the variable name and the value to set. Use the where parameter to limit the updates to specific rows.

To simplify, you can specify only a value for the var parameter. In this case, the other parameters in the list use default values.

The valueelement value can be one or more of the following:
"value":"string"
* "var":"variable-name"
Aliasname

* table={castable}

specifies the settings to apply to an input table.

To simplify, you can specify only a value for the name parameter. In this case, the other parameters in the list use default values.

For more information about this common parameter, see castable.

Result Descriptions

rowsUpdated

The result is a 64-bit integer. You can access the value from results.rowsUpdated.

tableName

The result is a string. You can access the value from results.tableName.