i need help
i need help

Reputation: 2386

Google Sheets formula to extract dates

I have this data in google sheets:

enter image description here

Looking to only get a date from the cell, example 1.4.2020

I tried something like below but doesn't work. Any idea what replacement to do?

=VALUE(REGEXREPLACE(B51,"[^[:digit:][:punct:]]", ""))

Upvotes: 0

Views: 245

Answers (2)

player0
player0

Reputation: 1

paste in C51:

=ARRAYFORMULA(IFNA(REGEXEXTRACT(B51:B54, "\d+\.\d+\.\d+")))

Upvotes: 1

JvdV
JvdV

Reputation: 76000

Yes try:

=REGEXEXTRACT(B51,"\d{1,2}\.\d{1,2}\.\d{4}")

Or if not other digits exists:

=REGEXEXTRACT(B51,"\d.*\d")

Upvotes: 1

Related Questions