Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[DOCS] dummydata 생성 #26

Merged
merged 3 commits into from
Oct 12, 2023
Merged

[DOCS] dummydata 생성 #26

merged 3 commits into from
Oct 12, 2023

Conversation

jinwooseok
Copy link
Contributor

어떤 내용에 대한 PR인가요?

현재 작성된 entity들을 기준으로 데이터를 생성했습니다. decision 제외

변경 사항

변경된 부분에 대한 상세한 내용을 나열해주세요

  1. vote_type는 현재 설정되어 있는 사항이 없기 때문에 "default"로 넣어놨고, image도 root정보가 들어가야하지만 현재 연결된 이미지저장소나 기능이 없기 때문에 문자열 "default"로 넣었습니다.
  2. decision은 만들어두지 않았습니다

무엇을 위주로 보면 좋을까요?

  1. docker에 db 데이터가 유지된다는 점이 있기 때문에 sql스크립트 첫 부분에 모든 테이블을 delete를 하고 시작합니다. 삭제할까요?
  2. create table을 포함할까요?

관련된 이슈

closes (#20)

테스트 방법

mysql workbench에 db스키마를 복사한 후에 테스트 진행

@jinwooseok jinwooseok linked an issue Oct 3, 2023 that may be closed by this pull request
1 task
@kssumin
Copy link
Contributor

kssumin commented Oct 8, 2023

아래에 01_create_table.sql, _02mock.sql
이런식으로 파일을 생성해주세요!!
그럼 docker 생성할 때 같이 해당 파일 올라가요!!

image

@jinwooseok jinwooseok added the Priority:Low 긴급 하지 않음 label Oct 8, 2023
auth_info_token varchar(255) not null,
auth_info_type varchar(255) not null,
user_id bigint null,
constraint FKh6sbxhkdcpohqbb8o42r34h1p
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

인덱스명 명확히 해주세요!
fk_user_entity_id

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

제가 해당 사항 반영하도록 하겠습니다!

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

감사합니다1

vote_category varchar(255) not null,
user_id bigint not null,
vote_active varchar(255) not null,
vote_content varchar(1000) null,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

이 부분도 사실 not null일 것 같은데 현재 저희가 설계를 null로 해두었네요...

추후 리팩터링 때 반영하면 될 것 같습니다.

option_vote_id bigint not null
);

create table user_entity
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

user_tb로 추후 리팩터링

"2023-10-20","continue","기본",NOW(), NOW(),false, 20);

INSERT INTO option_tb (option_id , option_name, option_count, option_vote_id, option_image, created_date, updated_date, deleted) VALUES (1, "캐쥬얼한 조끼니트",5,1,"default",NOW(), NOW(),false);
INSERT INTO option_tb (option_id , option_name, option_count, option_vote_id, option_image, created_date, updated_date, deleted) VALUES (2, "힙합!",10,1,"default",NOW(), NOW(),false);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

시간순 정렬이 있기 때문에 다 현시간 말고 다른 시간대도 넣어주세요!

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

넵 알겠습니다!

@kssumin kssumin merged commit 598c999 into weekly Oct 12, 2023
@jinwooseok jinwooseok deleted the docs/#20/docs-dummydata-sql branch October 17, 2023 15:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Priority:Low 긴급 하지 않음
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[DOCS] dummydata SQL 작성
3 participants