|
|
dh.ExecuteSql("update makeserial set ms_status=1,MS_ISACTIVE=0,ms_outboxcode='',ms_keyid='',ms_printcount = 0,ms_stepcode='', ms_nextstepcode= '" + stepcode + "',ms_paststep=case when instr(ms_paststep,'"+stepcode+"')>0 then substr(ms_paststep,0,instr(ms_paststep,'"+ stepcode + "')-2) else ms_paststep end where ms_sncode='" + sncode + "' and ms_makecode='" + makecode + "'", "update");
|
|
|
+ dh.ExecuteSql("update makeserial set ms_currentstep=REGEXP_SUBSTR(ms_paststep, '[^,]+$') where ms_sncode='" + sncode + "' and ms_makecode='" + makecode + "'", "update");
|