package sikd.sikd5.sikd5ejb.mapper;
/**
 * @author  : agus
 * @tanggal : Jan 25, 2019
 */

import java.util.List;

import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Result;
import org.apache.ibatis.annotations.Results;
import org.apache.ibatis.annotations.Select;

import sikd.sikd5.sikd5bean.query.PosisiKasAkunPerPemda;

public interface RefSimpatikMapper {
	@Select("select refsimpatikindex, tahunanggaran, kdakun, urakun, jenis, parentindex"
			+ " from simpatik.refsimpatik where tahunanggaran=#{tahun} and left(kdakun,1)=ANY(#{inAkun}) order by kdakun")
	@Results({
			@Result(property = "tahunanggaran", column = "tahunanggaran"),
			@Result(property = "kdakun", column = "kdakun"),
			@Result(property = "urakun", column = "urakun"),
			@Result(property = "jenis", column = "jenis"),
			@Result(property = "parentindex", column = "parentindex") })

	public List<PosisiKasAkunPerPemda> getRefsimpatiks(@Param("tahun") short tahun, @Param("inAkun") String[] inAkun);

}
