I want to split my string so it will take everything before NK-, SK-, DJ- or MU-
DJXFSE DJ-13 - ABC
MUEKOP MU-27 - ABC
DJXFSE DJ-12 - ABC
NOVA KNSEAC NK-26-4 - ABC
NOVA KNSEAC NK-26-9 - ABC
SRFI KRSIXUR SK-45 ABC2
So the output would be
DJXFSE
MUEKOP
DJXFSE
MUEKOP
DJXFSE
NOVA KNSEAC
NOVA KNSEAC
SRFI KRSIXUR
What would be the way to choose everything before (excluding) different possibilities of characters? I tried this
(^.*(?=(\ DJ)|(\ MU)))
where i thought that this part (\ DJ)|(\ MU) would mean DJ or MU, but i am obviously totally wrong.