Please enable JavaScript to use regex101
/
^
r
e
g
e
x
[
\
-
_
]
?
1
0
1
$
/
i
Reg
ular
Ex
pressions
101
Upgrade to Pro
Enterprise
Regular Expression
`
/product/(?:[^/]+/)*([^/]+)-[0-9]+$
`
gm
Input 1
1
New
i am trying to extract the product names from the URLs below using regex in Google BigQuery: https://www.example.com/en/uk/product/clothing/trousers-leggings/cool-grey-joggers-9800977 Product name should be: cool-grey-joggers https://www.example.com/en/uk/product/hot-denim-dress-7842666
Substitution
i am trying to extract the product names from the URLs below using regex in Google BigQuery: https://www.example.com/en/uk/product/clothing/trousers-leggings/cool-grey-joggers-9800977 Product name should be: cool-grey-joggers https://www.example.com/en/uk/product/hot-denim-dress-7842666