Leave a Reply

16 Comments on "Spring Boot Quick Start 29 – Making Crud Operations with Repository"

Notify of
avatar

Skullid13
Guest
Skullid13
3 days 9 hours ago

Thank you Rajesh

Michael Humpl
Guest
Michael Humpl
4 days 2 hours ago

Under the assumption that a user makes everything possible the following improvement proposal for time mark 10:00: As the example is currently written, it would be possible for the update that the id and topic.id are different. If only then save(topic) is called the database topic-entry for the passed id attribut is not deleted and remains available in the database. For this reason, I would extend the method updateTopic by the line "if (id != topic.id) { topicRepository.delete(id); }".

Neeraj Mahajan
Guest
Neeraj Mahajan
6 days 3 hours ago

Hi .. I am not able to find configuring external database video. Could you please let me know where I can find that ?

Christian Moen
Guest
Christian Moen
15 days 18 hours ago

what if you wanna connect to a existing mysql database source?

Phuc Tran
Guest
Phuc Tran
23 days 14 hours ago

I have 2 questions:1. I didn't see you create topic table in DB? how it map between entity object and topic table?2. if there are 2 DB, how we know which one is used? please tell me know DB configration

Nishin Kareem
Guest
Nishin Kareem
1 month 14 days ago

did you miss adding video to connect to external database (which you mentioned towards the end of the video)?

Deepak Sunanda Prabhakar
Guest
Deepak Sunanda Prabhakar
1 month 17 days ago
If I run the CourseApiApplication class I end up with this below error.Exception encountered during context initialization – cancelling refresh attempt: org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'org.springframework.boot.autoconfigure.orm.jpa.HibernateJpaAutoConfiguration': Unsatisfied dependency expressed through constructor parameter 0; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'dataSource' defined in class path resource [org/springframework/boot/autoconfigure/jdbc/DataSourceConfiguration$Tomcat.class]: Bean instantiation via factory method failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [org.apache.tomcat.jdbc.pool.DataSource]: Factory method 'dataSource' threw exception; nested exception is org.springframework.boot.autoconfigure.jdbc.DataSourceProperties$DataSourceBeanCreationException: Cannot determine embedded database driver class for database type NONE. If you want an embedded database please put a supported one on the classpath. If you… Read more »
Nhật Hoàng Minh Phạm
Guest
Nhật Hoàng Minh Phạm
1 month 4 days ago

add <dependency> <groupId>org.apache.derby</groupId> <artifactId>derby</artifactId> <scope>runtime</scope> </dependency>to pom.xml

salauddin
Guest
salauddin
2 months 4 days ago

what is use of id in updateTopic method in TopicService?

DivineRock89
Guest
DivineRock89
2 months 12 days ago

Can't we write getAllTopics method in one line of code? return (List<Topic>) topicRepository.findAll();

Sidikiba Bayo
Guest
Sidikiba Bayo
1 day 13 hours ago

Yes you can use and it will work just fine..

Harsh
Guest
Harsh
2 months 14 days ago

can you connect oracle DB with spring boot. please give the video about that

David Carey
Guest
David Carey
12 days 9 hours ago

I need to learn spring boot without learning spring framework can you suggest me any channel which helps me learning spring hibernate and every thing to develop enterprise applications.

Lazar Jovicic
Guest
Lazar Jovicic
2 months 13 days ago
hey buddy, I have done research about this but for mysql db. I have found that you have to use application.properties file*spring.datasource.url: jdbc:*//this is my configuration inside the app.prop file, change the driver, also make sure that you have all dependencies that you needmy pom.xml is* <parent> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-parent</artifactId> <version>1.4.3.RELEASE</version> </parent> <properties> <java.version>1.8</java.version> </properties> <dependencies> <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-data-jpa</artifactId> </dependency> <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-web</artifactId> </dependency> <dependency> <groupId>mysql</groupId> <artifactId>mysql-connector-java</artifactId> </dependency> <!– mvnrepository.com/artifact/com.fasterxml.jackson.core/jackson-core –> <dependency> <groupId>com.fasterxml.jackson.core</groupId> <artifactId>jackson-core</artifactId> <version>2.8.6</version> </dependency> <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-jdbc</artifactId> <version>1.3.5.RELEASE</version> </dependency><!– <dependency> <groupId>com.h2database</groupId> <artifactId>h2</artifactId> </dependency>–> <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-test</artifactId> <scope>test</scope> </dependency> </dependencies> <build> <plugins> <plugin> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-maven-plugin</artifactId> </plugin> </plugins> </build> <pluginRepositories> <pluginRepository>… Read more »
wpDiscuz