In this instance I want to retrieve the phrase right before JV. Here i have a regex that pulls this but I anticipate it may need more flexibility. For example, if after the highlighted piece the combination may have more letters after a number phrase, need ideas on how to make more robust. For example, this statement captures values such as this INV-079037 JV but it does not capture values such as this 103585 JV so I am jumping into a rabbit hole. In each statement the phrase would be immediately before JV and after a preceeding space. Here are several lines of text
Remit Vendor Vendor Voucher ID Invoice ID Invoice Dt Bus Unit Entered Dt Origin Operator Entry Status Post Status
000611810 000611810 01490973 103585 JV 1/5/2022 100GP 2/4/2022
or
Remit Vendor Vendor Voucher ID Invoice ID Invoice Dt Bus Unit Entered Dt Origin Operator Entry Status Post Status
0000058195 0000058195 01490976 INV-079037 JV 12/31/2021 100GP 2/4/2022
Any input would be helpful