Skip to content

Get

Lookups a data table row from dictionary.

1
myDataTableDictionary.Get(key: string):( DataRow | Array<DataRow> )

Parameters

string key
    Data table row key

Returns

Returns the matching object from DataTableDictionary if found, otherwise returns null.

Remarks

If key value trimmed if starts with numeric 0 characters if not contain any '.' (dot) character. For example : '00001234' key becomes '1234' but '000.1234' preserved.
If multiple rows matched with key an matching object array is returns.

Example

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
var table = $Database.Get({
    Parameters : {
        TargetSchema : 'HR',
        TargetTable : 'Groups'
    }
});

var list = table.ToDictionary('Name');

var myGroup = list.Get("MyGroup");

See Also