apply .gitignore clean-up
Change-Id: Idd0b57a7340f0e62c85090d84c4fdb8cb5d6fe00
diff --git a/src/main/resources/mapper/FavoriteMapper.xml b/src/main/resources/mapper/FavoriteMapper.xml
index 1048ec2..2c9abe4 100644
--- a/src/main/resources/mapper/FavoriteMapper.xml
+++ b/src/main/resources/mapper/FavoriteMapper.xml
@@ -2,5 +2,5 @@
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.example.myproject.mapper.FavoriteMapper">
-
+ <select id="selectByUserId" resultType="com.example.myproject.entity.FavoriteEntity"> SELECT * FROM favorite WHERE user_id = #{userId} </select>
</mapper>
diff --git a/src/main/resources/mapper/SeedRatingMapper.xml b/src/main/resources/mapper/SeedRatingMapper.xml
new file mode 100644
index 0000000..34fa7a0
--- /dev/null
+++ b/src/main/resources/mapper/SeedRatingMapper.xml
@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="com.example.myproject.mapper.SeedRatingMapper">
+ <select id="selectHighRatingsByUserId" resultType="com.example.myproject.entity.SeedRating">
+ SELECT * FROM seed_rating
+ WHERE user_id = #{userId}
+ AND score >= 7
+ </select>
+
+ <select id="selectBySeedIds" resultType="com.example.myproject.entity.SeedRating">
+ SELECT * FROM seed_rating WHERE seed_id IN
+ <foreach collection="seedIds" item="id" open="(" separator="," close=")">
+ #{id}
+ </foreach>
+ </select>
+</mapper>
\ No newline at end of file