Skip to Content
Oct 22, 2019 at 12:40 AM

How to get domain name from email address in a webi 4.2 report?


I have email addresses like,, etc. I want a variable formula in webi report  that will trim user names and .com and return output as gmail,ymail,hotmail

Like below.But in webi I cant use instr/charindex/substring_index.
select(SUBSTRING_INDEX(SUBSTR(email, INSTR(email,'@')+1),'.',1))as a,count(*)as c
FROMUsergroupby a orderby c desc;