diff --git a/src/main/java/com/example/naverrestaurant/db/H2DbRepositoryAbstract.java b/src/main/java/com/example/naverrestaurant/db/H2DbRepositoryAbstract.java index 426d0e3..2b43471 100644 --- a/src/main/java/com/example/naverrestaurant/db/H2DbRepositoryAbstract.java +++ b/src/main/java/com/example/naverrestaurant/db/H2DbRepositoryAbstract.java @@ -66,7 +66,12 @@ public void deleteById(int index) { String deleteByIdQuery = "delete from restaurant where index=?"; int deleteByIdParam = index; int result = this.jdbcTemplate.update(deleteByIdQuery, deleteByIdParam); - System.out.println("delete : "+result); + if(result==1){ + System.out.println("delete success"); + } + else if(result==0){ + System.out.println("delete fail"); + } } @Override