나JAVA봐라
테이블 (14)
accidentBoard (사건사고 게시판)
- 순번 (num) — int not null primary key auto_increment — 기본 키 — NOT NULL
- 글제목 (title) — varchar(20) not null
- 글내용 (content) — varchar(100) not null
- 작성일자 (postdate) — datetime not null default current_timestamp
- 조회수 (visitcount) — int not null default 0
- 좋아요 (likes) — int not null default 0
- 싫어요 (dislikes) — int not null default 0
- 작성자 (id) — varchar(20) not null — 외래 키 → user.아이디 — NOT NULL
accidentBoardComments (사건사고 게시판 댓글)
- 댓글순번 (commentNum) — int not null primary key auto_increment — 기본 키
- 댓글 (comment) — text not null
- 작성일자 (regDate) — datetime not null default current_timestamp
- 작성자 (writer) — varchar(50) not null — 외래 키 → user.아이디 — NOT NULL
- 사건사고 게시물 순번 (postNum) — int not null primary key auto_increment — 외래 키 → accidentBoard.순번 — NOT NULL
comments (동네친구 게시판 댓글)
- 댓글순번 (commentNum) — int primary key not null auto_increment — 기본 키 — NOT NULL
- 댓글 (comment) — text not null
- 작성일 (regDate) — timestamp current_timestamp
- 댓글 작성자 (id) — varchar(20) not null unique — 외래 키 → user.아이디 — NOT NULL
- 동네친구 게시물 순번 (postNum) — int not null primary key auto_increment — 외래 키 → friendBoard.순번 — NOT NULL
freeBoard (자유게시판)
- 순번 (num) — int not null primary key auto_increment — 기본 키 — NOT NULL
- 글제목 (title) — varchar(24) not null
- 글내용 (content) — varchar(200) not null
- 작성일자 (postdate) — datetime not null default current_timestamp
- 조회수 (visitcount) — int not null default 0
- 작성자 (id) — varchar(24) not null — 외래 키 → user.아이디 — NOT NULL
friendBoard (동네 친구 게시판)
- 순번 (num) — int not null primary key auto_increment — 기본 키 — NOT NULL
- 글제목 (title) — varchar(24) not null
- 글내용 (content) — varchar(200) not null
- 작성일자 (postdate) — datetime not null default current_timestamp
- 조회수 (visitcount) — int not null default 0
- 좋아요 (likeCount) — int default 0
- 지역 (area) — varchar(255) not null
- 작성자 (id) — varchar(24) not null — 외래 키 → user.아이디 — NOT NULL
friendBoardFiles (동네 친구 게시판 파일)
- 파일id (fileId) — int not null primary key auto_increment — 기본 키
- 파일이름 (fileName) — varchar(255) not null
- 원본파일이름 (ofileName) — varchar(255) default is null
- 게시물 순번 (postNum) — int not null — 외래 키 → friendBoard.순번 — NOT NULL
hobbyBoard (취미 게시판)
- 순번 (num) — int not null primary key auto_increment — 기본 키 — NOT NULL
- 취미 (hobby) — ENUM('gardening', 'art', 'cook', 'puzzle', 'collection', 'reading', 'exercise', 'photo', 'handmade', 'instrument', 'astronomical') not null
- 글제목 (title) — varchar(200) not null
- 글내용 (content) — varchar(2000) not null
- 원본파일명 (orifile) — varchar(200) not null
- 저장파일명 (newfile) — varchar(200) not null
- 작성일자 (postdate) — datetime not null default current_timestamp
- 조회수 (visitcount) — int not null default 0
- 작성자 id (id) — varchar(20) not null — 외래 키 → user.아이디 — NOT NULL
hobbyComments (취미 게시판 댓글)
- 댓글id (numx) — int not null primary key auto_increment — 기본 키
- 댓글 (content) — VARCHAR(2000) not null
- 작성일자 (postdate) — datetime not null default current_timestamp
- 아이디 (id) — varchar(20) not null — 외래 키 → user.아이디 — NOT NULL
- 취미 게시물 순번 (num) — int not null — 외래 키 → hobbyBoard.순번 — NOT NULL
regionBoard (지역별 게시판)
- 순번 (num) — int not null primary key auto_increment — 기본 키 — NOT NULL
- 글제목 (title) — varchar(20) not null
- 글내용 (content) — varchar(100) not null
- 작성일자 (postdate) — datetime not null default current_timestamp
- 조회수 (visitcount) — int not null default 0
- 원본파일이름 (ofile) — text default is null
- 파일명 (sfile) — text default is null
- 좋아요 (likes) — int not null default 0
- 작성자 (id) — varchar(20) not null — 외래 키 → user.아이디 — NOT NULL
regionLike (지역 게시판 좋아요)
- 좋아요 순번 (likenum) — int not null primary key auto_increment — 기본 키
- 좋아요 날짜 (likedate) — datetime not null default current_timestamp
- 아이디 (id) — varchar(24) not null — 외래 키 → user.아이디 — NOT NULL
- 지역게시판 게시물 순번 (num) — int not null primary key auto_increment — 외래 키 → regionBoard.순번 — NOT NULL
replies (동네친구 게시판 답글)
- 답글순번 (replyNum) — int not null primary key auto_increment — 기본 키
- 답글 (reply) — text not null
- 작성일자 (regdate) — datetime not null default current_timestamp
- 답글 작성자 (writer) — varchar(100) not null — 외래 키 → user.아이디 — NOT NULL
- 댓글순번 (commentNum) — int primary key not null auto_increment — 외래 키 → comments.댓글순번 — NOT NULL
reviewBoard (장소 리뷰 게시판)
- 순번 (num) — int not null primary key auto_increment — 기본 키 — NOT NULL
- 글제목 (title) — varchar(1000) not null
- 글내용 (content) — varchar(2000) not null
- 작성일자 (postdate) — datetime not null default current_timestamp
- 조회수 (visitcount) — int not null default 0
- 원본파일명 (originalFile) — varchar(200)
- 저장파일명 (newFile) — varchar(200)
- 작성자 id (id) — varchar(20) not null — 외래 키 → user.아이디 — NOT NULL
reviewcomments (장소 리뷰 게시판 댓글)
- 댓글 (comment) — VARCHAR(2000)
- 작성일자 (postdate) — datetime not null default current_timestamp
- 장소 리뷰 게시물 순번 (num) — int not null — 외래 키 → reviewBoard.순번 — NOT NULL
- 아이디 (id) — varchar(20) not null — 외래 키 → user.아이디 — NOT NULL
user (회원)
- 아이디 (id) — varchar(20) not null primary key unique — 기본 키 — NOT NULL
- 비밀번호 (pw) — varchar(20) not null
- 이름 (name) — varchar(20) not null
- 지역 (area) — varchar(20) not null
- 역할 (role) — varchar(20) not null
- 가입일자 (regdate) — datetime not null default current_timestamp