i have got this text file
AAAA
1234
title example
Lorem Ipsum
FF
AAAA
1234
title example
€330 - Roma
FF
I want to extract from this file only the txt that:
START WITH AAAA
HAS Euro SYmbol
END WITH FF
In this case i want to match only that
AAAA
1234
title example
€330 - Roma
FF
I tried with different solution i used
sed -e '/AAAAs/,/europ/,/FF/!d' testfile.txt
but it extract all txet between AAAA and FF
How can i solve it?
Thanks for help
EDIT:
between euro line and FF there could be some text. i don't know how many lines..
AAAA
1234
title example
€330 - Roma
Some text with \n, comma symbol etc etc
FF
i wat to extract the txt between AAAA and FF