Script functions reference > Script functions in alphabetical order > S > SetMap

SetMap
Syntax
SetMap(str_Mapname, str_key, num_index, str_value);
str_Mapname 
str_key 
num_index 
str_value 
Description
Assigns str_value to the value column num_col of the specified map entry. The map is specified by str_Mapname, and the map entry is specified by str_key.
If the map or entry does not exist, it is created.
Returns
N/A
Example
In this example, the following map (author) is used.
agatha christie   1890
alfred h          1899
The following script modifies the map entry alfred, and adds the map entry astrid:
SetMap("author","alfred",0,"hitchcock");
SetMap("author","astrid",0,"lindgren");
SetMap("author","astrid",1,"1907");
After the script is executed, author is changed as follows:
agatha christie    1890
alfred hitchcock   1899
astrid lindgren    1907
OpenText StreamServe 5.6.2 Updated: 2018-01-26