update db_xcall_cdr.cdr c1 inner join db_xcall_cdr.cdr c2 on c1.accountcode=c2.accountcode set c1.extension=c2.extension, c1.recordingfile=c2.recordingfile where c1.accountcode=pstr_accountcode and c1.direction=2 and c2.direction =2 and c2.dtmf='' and c1.dtmf <> '';