package com.nokia.tsl_data.dao;

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

@Mapper
public interface ComplaintDetailsFixYwdDayMapper {

    @Select("select count(1) from tsl_data.complaint_details_fix_ywd_day where month_id = #{month_id} and day_id = #{day_id}")
    int countForDay(@Param("month_id") String monthId, @Param("day_id") String dayId);

    default int countForDay(String day) {
        return countForDay(day.substring(0, 6), day.substring(6));
    }
}
