Hello Folks,
I have a requirement to extract the domains from a list of URLs. I know this is quite trending and a petty common topic across generic internet search, however no formulas quite seem to match my specific query.
My file has a list of domains (which include subdomains and multiple TLDs). I only need to extract the parent domain and strip off any subdomain or TLD(s) from the list.
Example:
[TABLE="width: 500"]
<tbody>[TR]
[TD]Domain[/TD]
[TD]Extracted[/TD]
[/TR]
[TR]
[TD]www.sub.domain.com[/TD]
[TD]domain[/TD]
[/TR]
[TR]
[TD]https://sub.domain2.com[/TD]
[TD]domain2[/TD]
[/TR]
[TR]
[TD]domain3.com.ru[/TD]
[TD]domain3[/TD]
[/TR]
[TR]
[TD]www.sub2.domain4.com.fl[/TD]
[TD]domain4[/TD]
[/TR]
[TR]
[TD]sub1.sub2.domain5.org.fl[/TD]
[TD]domain5[/TD]
[/TR]
</tbody>[/TABLE]
Note: there are multiple TLDs and multiple sub-domains. I know its quite troublesome, but would be great if someone can help.
Thanks
I have a requirement to extract the domains from a list of URLs. I know this is quite trending and a petty common topic across generic internet search, however no formulas quite seem to match my specific query.
My file has a list of domains (which include subdomains and multiple TLDs). I only need to extract the parent domain and strip off any subdomain or TLD(s) from the list.
Example:
[TABLE="width: 500"]
<tbody>[TR]
[TD]Domain[/TD]
[TD]Extracted[/TD]
[/TR]
[TR]
[TD]www.sub.domain.com[/TD]
[TD]domain[/TD]
[/TR]
[TR]
[TD]https://sub.domain2.com[/TD]
[TD]domain2[/TD]
[/TR]
[TR]
[TD]domain3.com.ru[/TD]
[TD]domain3[/TD]
[/TR]
[TR]
[TD]www.sub2.domain4.com.fl[/TD]
[TD]domain4[/TD]
[/TR]
[TR]
[TD]sub1.sub2.domain5.org.fl[/TD]
[TD]domain5[/TD]
[/TR]
</tbody>[/TABLE]
Note: there are multiple TLDs and multiple sub-domains. I know its quite troublesome, but would be great if someone can help.
Thanks