diff --git a/ddl/schema.sql b/ddl/schema.sql index d298e83..271005d 100644 --- a/ddl/schema.sql +++ b/ddl/schema.sql @@ -11,6 +11,8 @@ password varchar(100) not null, user_id varchar(100) not null, refresh_token varchar(200), - primary key (oid), - constraint uk_member_user_id unique (user_id) + primary key (oid) ); + + create index idx_member_user_id + on st_member (user_id); diff --git a/src/main/java/com/bio/bio_backend/domain/user/member/entity/Member.java b/src/main/java/com/bio/bio_backend/domain/user/member/entity/Member.java index 2421ef6..e1ee717 100644 --- a/src/main/java/com/bio/bio_backend/domain/user/member/entity/Member.java +++ b/src/main/java/com/bio/bio_backend/domain/user/member/entity/Member.java @@ -18,8 +18,8 @@ import java.time.LocalDateTime; @Builder @Table( name = "st_member", - uniqueConstraints = { - @UniqueConstraint(name = "uk_member_user_id", columnNames = "user_id") + indexes = { + @Index(name = "idx_member_user_id", columnList = "user_id") } ) public class Member extends BaseEntity {