I have some log lines that sometimes have a description appended, in the "Details: bla bla bla" string.
The first and third lines have it here:
Naam: St Nationaal Epilepsie Fon ds/ de Macht Vh Kleine Machtiging: MBOA-652563-1 Details: Incasso januari donatie IBAN: NL83INGB0000222111 Kenmerk: 5920010020375704
Naam: LE EITHNE
Naam: DOMINOS NL BY ADYEN Details: 4314566010481582 0 030001485229518 Dominos Pizza Kenmerk: 27-02-2016 20:24 003000 1485229518
Naam: Clark Kent 121 Fake street, bla bla black sheep, north pole
I want to extract the Details into its own field using a capture group with an optional ()?.
CREDITOR_NAME %{GREEDYDATA}
DESCRIPTION %{GREEDYDATA}
LOGLINE Naam: %{CREDITOR_NAME:CreditorName}%{SPACE}(Details: %{DESCRIPTION:Description})?
If I make it optional however it doesn't work, the previous CreditorName eats all the remainder of the line. If I make it mandatory it only works for those lines that have Details, the other fail.
I've tried a bunch of variations, including using non-greedy DATA but nothing seems to work.
Any pointers would be greatly appreciated!