package market.Qms.metallurgy.mapper;

import market.Qms.metallurgy.vo.ComMscStdSpecBiasC;

import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;
import org.apache.ibatis.annotations.Update;

import com.hnshituo.orm.GenericMapper;

public interface ComMscStdSpecBiasCMapper extends GenericMapper<ComMscStdSpecBiasC, Object> {

	@Select("select nvl(max(t.index_seq),0)+1 from  com_msc_std_spec_bias_c t where t.sic = #{sic}")  
	Integer getIndexNo(@Param("sic") String sic);
	
	@Update("UPDATE com_msc_std_spec_bias_c SET DELETE_NAME=NULL,DELETE_TIME=NULL,VALIDFLAG=1 WHERE SIC = #{sic} AND INDEX_SEQ = #{index}")
	public void updatef(@Param("sic") String sic,@Param("index") Integer index);
}
