|
| 1 | +# [searchbnf.conf](http://docs.splunk.com/Documentation/Splunk/latest/Admin/Searchbnfconf) |
| 2 | + |
| 3 | +[countmatches-command] |
| 4 | +syntax = countmatches fieldname=<field> pattern=<regular_expression> \ |
| 5 | + <field-list> |
| 6 | +alias = |
| 7 | +shortdesc = Counts the number of non-overlapping matches to a regular \ |
| 8 | + expression in a search result. |
| 9 | +description = A count of the number of non-overlapping matches to the regular \ |
| 10 | + expression specified by pattern is computed for each record processed. |
| 11 | + The result is stored in the field specified by fieldname. If fieldname \ |
| 12 | + exists, its value is replaced. If fieldname does not exist, it is \ |
| 13 | + created. Results are otherwise passed through to the next pipeline \ |
| 14 | + processor unmodified. |
| 15 | +comment1 = Count the number of words in the text of each tweet in tweets.csv \ |
| 16 | + and put the result in word_count. |
| 17 | +example1 = | inputcsv tweets.csv | countmatches fieldname=word_count \ |
| 18 | + pattern="\\w+" text |
| 19 | +category = fields::add |
| 20 | +appears-in = 5.0 |
| 21 | +maintainer = dnoble |
| 22 | +usage = public |
| 23 | +related = stats |
| 24 | +tags = searchcommands_app |
| 25 | + |
| 26 | +[simulate-command] |
| 27 | +syntax = simulate csv=<path> rate=<expected_event_count> \ |
| 28 | + interval=<sampling_period> duration=<execution_period> (seed=<string>)? |
| 29 | +alias = |
| 30 | +shortdesc = Generates a sequence of events drawn from a csv file using \ |
| 31 | + repeated random sampling. |
| 32 | +description = The simulate command uses repeated random samples of the event \ |
| 33 | + records in csv for the execution period of duration. Sample sizes are \ |
| 34 | + determined for each time interval in duration using a Poisson distribution \ |
| 35 | + with an average rate specifying the expected event count during interval. |
| 36 | +comment1 = Generate events drawn by repeated random sampling of events in \ |
| 37 | + tweets.csv. |
| 38 | +example1 = | simulate csv=population.csv rate=50 interval=00:00:01 \ |
| 39 | + duration=00:00:05 |
| 40 | +category = results::generate |
| 41 | +appears-in = 5.0 |
| 42 | +maintainer = dnoble |
| 43 | +usage = public |
| 44 | +related = inputcsv |
| 45 | +tags = searchcommands_app |
| 46 | + |
| 47 | +[sum-command] |
| 48 | +syntax = sum total=<field> <field-list> |
| 49 | +alias = |
| 50 | +shortdesc = Computes the sum of a set of fields. |
| 51 | +description = The total produced is sum(sum(fieldname, 1, n), 1, N) where n = \ |
| 52 | + number of fields, N = number of records. |
| 53 | +comment1 = This example computes the total linecount in the first 200 records \ |
| 54 | + in the _internal index. |
| 55 | +example1 = index = _internal | head 200 | sum total=lines linecount |
| 56 | +category = reporting |
| 57 | +appears-in = 5.0 |
| 58 | +maintainer = dnoble |
| 59 | +usage = public |
| 60 | +related = stats |
| 61 | +tags = searchcommands_app |
0 commit comments