Quantcast
Channel: Hot Weekly Questions - Web Applications Stack Exchange
Viewing all articles
Browse latest Browse all 9626

How to extract time out of text after specific word in Google Sheets with regex function

$
0
0

I hope someone can help me with my struggle. I need to get the time slots after each "Text_Text" from this one sentence that is in a single cell:

Sth 03/30/2020 1:15 PM-03/30/2020 1:30 PM;"Text_Text" 03/30/2020 1:30 PM-03/30/2020 3:30 PM;"Sth" 03/30/2020 3:30 PM-03/30/2020 4:00 PM;"Text_Text" 03/30/2020 4:00 PM-03/30/2020 4:30 PM;"Sthh" 03/30/2020 6:00 PM-03/30/2020 6:15 PM;

Desired outcome:start time and end time in different cells: 1:30 PM 3:30 PM 4:00 PM 4:30 PM

The pattern and length of the sentence are not consistent. But time always comes after "Text_Text" and the date. I am working in Google Sheets . I know that this could be done with regex but it's too confusing for me and I can't get the syntax right. So far i was only able to get only 1 slot with split function but this is far way from what I need.


Viewing all articles
Browse latest Browse all 9626

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>