create table tab1(mail_id varchar2(50));
insert into tab1 values('siva.k.academy@gmail.com');
insert into tab1 values('jeevan.anand@yahoo.com');
insert into tab1 values('ravi@outlook.com');
commit;
select * from tab1;
with d1 as (select mail_id m,
substr(mail_id,1, instr(mail_id,'@')-1) n,
substr(mail_id, instr(mail_id,'@')+1) d
from tab1),
d2 as (select m,d,n,
instr(n,'.',1,1) f_dot ,
instr(n,'.',1,2) s_dot
from d1),
d3 as (select m,d,n,f_dot,s_dot,
substr(n,1,decode(f_dot,0,length(n),f_dot-1)) f_name,
decode(s_dot,0,null,substr(n,f_dot+1,s_dot-f_dot-1)) m_name,
decode(f_dot+s_dot,0,null,substr(n,decode(s_dot,0,f_dot,s_dot)+1)) l_name
from d2)
select m,f_name,m_name,l_name
from d3;
Written in very Well Mannered By doing so, it facilitates efficient data management, enabling users to organize and analyse information more effectively from the help of flutter app development company who can make your app for this from which you will get mass success. Such functionality is particularly useful in scenarios where email addresses serve as identifiers, allowing for personalized communication or targeted data processing. Overall, this query enhances data processing capabilities and streamlines information retrieval processes.
ReplyDelete