with table
with table ( table name, row number ) statement;
with table ( table name, row number ) {statements; }
This procedure provides a table context which allows using partial table specificactions in the subsequent statement or code block. If a context is already available, then it will be superseded until the end of the statement or code block.
Indirect parameter passing is disabled
This function provides a table context for partial table specifications with table name, row number and optionally column number
2
No. | Type | Description |
---|---|---|
1. input |
string | Table Name Name of exsting table |
2. input |
numeral | Row Number Row number to apply apply |
table initialize ( colors, { { EN, FR }, { red, rouge }, { blue, blue }, { green, vert }, { yellow, jaune } } );
with table ( colors, 2 )
{
echo( row(), ": ", [EN]," / ", [FR] );
}
// Without the context, the full table specification is requierd, see below
echo( "2: ", [colors:EN,2]," / ", [colors:FR,2] );
2: blue / blue
2: blue / blue
table load( cities, "Examples\Cities.csv" );
for (a[]=1, a[]<=4, a[]++)
with table( cities, 2, a[] )
{
echo("Header : ", [.,0], new line, "Contents: ", [.], new line );
}
Header : City
Contents: Washington
Header : State/Province
Contents: D.C.
Header : Inhabitants
Contents: 650000
Header : Famous attraction
Contents: Lincoln Statue