grepSynopsisset grep(set data, string re) DescriptionThe grep command takes in two arguments--a set, and a string, and returns a set which consists of all members of the parameter set data which match the regular expression given in the parameter string re. A detailed description of regular expressions supported by QL can be found on the operators page. ExampleIn this example we create a test set, and then use the grep command to select only the entries with "a" as their second letter: >> animals= {"dog", "cat", "mouse", "moose", "hamster", "human", "iguana"} >> grep (animals , ".a.*") cat hamster >> See AlsoRegular Expression Guide |