Hi,
I need help in extracting only the phone numbers between the continuous non empty xml tags in unix. I searched through a lot of forum but i did not get exact result for my query. Please help
Given below is the sample pipe delimited file. I have a lot of tags before and after ...<phone>...</phone>... tags
Sample file:
|<phone>|<number>1234567890</number>|<type>primary</type>|</phone>|
|<phone>|<number>2345678999</number>|<type >primary</type>|</phone>|
|<phone>|<number>3214325432</number>|<type>primary</type>|</phone>|
|<phone>|<number>9876543210</number>|<type>primary</type>|</phone>|
|<phone>|<number>4567896789</number>|<type>primary</type>|</phone>|
Expected Output:
1234567890
2345678999
3214325432
9876543210
4567896789