ویدئو 3 -- اسپرینگ بوت و بانک اطلاعاتی -- Java Spring Boot Entitiy, Database
164 بار بازدید -
4 سال پیش
-
DATABASE TABLES AND THE RESPECTIVE
DATABASE TABLES AND THE RESPECTIVE ENTITIES IN JAVA SPRING BOOT
===============================================================
We create a database table and define its columns as variables in the entity
Entities represent database tables. These are entities that we have in our Java Spring Boot application. They will have services and repositories associated with them. A set of annotations clarify the class, including Lombok annotations. The @Entity annotation is important. The @Table(name="tablename") is an example of an annotation to give
tablename. The @Id annotation defines the id field. The @GeneratedValue annotation may be applied to a primary key property.
We can define the relationship between tables using
@ManyToOne, @OneToMany, and @ManyToMany annotations.
4 سال پیش
در تاریخ 1399/07/03 منتشر شده
است.
164
بـار بازدید شده