Access the full course here: javabrains.io/courses/spring_bootquickstart
Learn how to create a Repository interface using Spring Data JPA.
9 Comments on "Spring Boot Quick Start 28 – Creating a Spring Data JPA Repository"
may be a silly question but….the annotation you are using are provide by whom…Spring MVC?Please do replythank you
What if I am having composite ID in an Entity, and also many different type of entities to be persisted. Do I need to create that many number of interfaces ?
Field topicRepository in io.javabrains.springbootquickstart.topic.TopicService required a bean of type 'io.javabrains.springbootquickstart.topic.TopicRepository' that could not be found. problem
very well explained. Good effort.Appreciated.Thanks !!
Here's the dependency we need to add to pom.xml if you are not seeing this import "javax.persistence.Entity"<!– mvnrepository.com/artifact/org.springframework.data/spring-data-jpa –> <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-data-jpa</artifactId> </dependency>
Thank you Rajesh, great video
Hey KoushikYour tutorials are awesome. I have this one doubt. You said CrudRepository is a class and declared TopicRepository as an interface. In Java an interface cann't extend a class right?
crudRepository is an Interface, and in Java an Interface can extend another Interface, not "implements"
In CodeChannels.com, you can learn to code by watching videos and stay up to date with latest code shows, events and tutorials aggregated from various leading developer communities.
Copyright 2016 By CodeChannels.com All rights reserved.