简体   繁体   中英

split file based on multiple delimiters

Is it Possible to split a file based on multiple delimiters using Pig

example: I have a file as below

 abc|123>xyz:amd<yts abd|124>xyz:amc<yts 

is it possible to split based on |,>,:,< and get the output stored as

 abc|123|xyz|amd|yts abd|124|xyz|amc|yts 

Thanks

it is easier to capture what you want instead of splitting using this pattern

([^|>:<]+)

Demo

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM