The goal is to capture each item in this text file and add row to a dataverse table. I'm thinking I would need to capture everything from W2* until the next W2* and then parse.
HEADER INFORMATION- shows up once. This is like the flight info- Delta flight 005, from Atlanta to London- Heathrow, carrying 307 passengers, 12 crew members, 176,413 pounds weight at take-off- blah blah
#UPT UP 4628SWACO002412202049RMXXCORP/
GS*IC*UP*CORP*20241220*2049*10176*X*008030
ST*418*101760001
BAX*855638*L*139*20241220*1849*OFFERING*855638
W1*CORP
RAILCAR INFORMATION- Repeats for as many railcars are on the train. This would be where each individuals passenger information is included.
W2*GGCX*5843*2821141*RR*L*98*********C214
W3*515582*20241206*ATKOREPLAPIP*EUGENE*OR
W4*WESTLACHEVIN*UP*53714*ALLEMANIA*LA
W5*UP*EUGEN*CORP
Question is how can I extract the railcar information for each?