What Fabien suggested just rang a bell for me, but wouldn't "context-values" or "context-lookup" template functions suit your need? I have copied the admin guide's referring part: context-values Syntax: $(context-values $name-value1 $name-value2 ...) Description: The context-values template function returns a list of every occurrence of the specified name-value pairs from the entire context. For example, if the context contains multiple messages, the $(context-values ${HOST}) template function will return a comma- separated list of the ${HOST} values that appear in the context. Sorry if I'm wrong, these are just my 2 cents. Regards, Gabor ________________________________ From: syslog-ng <syslog-ng-bounces@lists.balabit.hu> on behalf of Fabien Wernli <wernli@in2p3.fr> Sent: Wednesday, October 2, 2019 14:49 To: Fabien Wernli <wernli@in2p3.fr> Cc: Syslog-ng users' and developers' mailing list <syslog-ng@lists.balabit.hu> Subject: Re: [syslog-ng] group-by() send all messages to destination() ? CAUTION: This email originated from outside of the organization. Do not follow guidance, click links, or open attachments unless you recognize the sender and know the content is safe. Hi again, On Wed, Oct 02, 2019 at 09:40:21AM +0200, Fabien Wernli wrote:
message, but that won't help you as you can't (AFAIK) loop through the backref index. What you might be able to do is use the `$(grep)` function
Actually, you cannot yet, but might be able to soon(ish): https://nam05.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fsyslog-ng%2Fsyslog-ng%2Fissues%2F2926%23issuecomment-536985104&data=02%7C01%7Cgabor.nagy%40oneidentity.com%7Cd8fd2a28102c40e4b3e108d7473701e0%7C91c369b51c9e439c989c1867ec606603%7C0%7C0%7C637056173904330670&sdata=bL%2F1iPWAL%2BIlisuFxI7narwNHX%2BhfN%2F4XW5XxVC94kY%3D&reserved=0 ______________________________________________________________________________ Member info: https://nam05.safelinks.protection.outlook.com/?url=https%3A%2F%2Flists.balabit.hu%2Fmailman%2Flistinfo%2Fsyslog-ng&data=02%7C01%7Cgabor.nagy%40oneidentity.com%7Cd8fd2a28102c40e4b3e108d7473701e0%7C91c369b51c9e439c989c1867ec606603%7C0%7C0%7C637056173904330670&sdata=NG8ADuvQSRrE2KvMd3GqNo3GmeVB6dfdLcZx7kLyhHM%3D&reserved=0 Documentation: https://nam05.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.balabit.com%2Fsupport%2Fdocumentation%2F%3Fproduct%3Dsyslog-ng&data=02%7C01%7Cgabor.nagy%40oneidentity.com%7Cd8fd2a28102c40e4b3e108d7473701e0%7C91c369b51c9e439c989c1867ec606603%7C0%7C0%7C637056173904330670&sdata=Q5Z6vt3LfDPQUxAoWZAGZuApFeAq4djyoIe6jGYsRPk%3D&reserved=0 FAQ: https://nam05.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.balabit.com%2Fwiki%2Fsyslog-ng-faq&data=02%7C01%7Cgabor.nagy%40oneidentity.com%7Cd8fd2a28102c40e4b3e108d7473701e0%7C91c369b51c9e439c989c1867ec606603%7C0%7C0%7C637056173904330670&sdata=EIOR2ql5puj1UnWHgaRWqvm0p066Xrp0cAqY8nTEp1I%3D&reserved=0