Notice
Recent Posts
Recent Comments
Link
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | ||||||
2 | 3 | 4 | 5 | 6 | 7 | 8 |
9 | 10 | 11 | 12 | 13 | 14 | 15 |
16 | 17 | 18 | 19 | 20 | 21 | 22 |
23 | 24 | 25 | 26 | 27 | 28 |
Tags
- Oracle
- 네트워크
- 참조타입
- NCS
- javaee
- ciscopacket
- 이것이 자바다
- rinux
- 데이터베이스
- php
- 네트워크관리사
- jsp연결
- Java
- 리눅스
- autoset
- Cisco
- 자바
- 버추얼머신
- 라우터
- 오라클
- w3school
- ospf
- 정보처리기사
- 정처기필기
- 원형그래프
- jsp
- cisco packet
- sql
- VLAN
- html
Archives
- Today
- Total
기록해! 정리해!
JPA 스타트 (테이블 생성 후 오라클에서 확인하기) 본문
1. 프로젝트생성


2. application.properties
# 주석 ( none , servlet )
spring.main.web-application-type=servlet
server.port=8888
# 오라클 컨넥션 정보
spring.datasource.driver-class-name=oracle.jdbc.driver.OracleDriver
spring.datasource.url =jdbc:oracle:thin:@localhost:1521:xe
spring.datasource.username=system
spring.datasource.password=1234
## JPA Setting
spring.jpa.hibernate.ddl-auto=update
spring.jpa.generate-ddl=false
spring.jpa.show-sql=true
spring.jpa.database-platform=org.hibernate.dialect.OracleDialect
spring.jpa.properties.hibernate.format_sql=true
# JSP 경로 설정
# spring.mvc.view.prefix=/WEB-INF/view/
# spring.mvc.view.suffix=.jsp
#### 다중 mapper 설정하기
# mybatis.mapper-locations=classpath:mapper/**/*.xml
#thymeleaf cache setting
spring.thymeleaf.cache=false
3. Board

package com.rubypaper.board;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.Table;
import lombok.Data;
@Data
@Entity
@Table(name="Board1017")
public class Board {
@Id
@GeneratedValue
private Long seq;
private String title;
}
4. 실행 시 콘솔창에 테이블 생성된 것을 확인할 수 있다
>> 오라클에서 확인해보기
'SpringBoot' 카테고리의 다른 글
JPA - Board(Junit-1) (0) | 2022.10.17 |
---|---|
JPAJarTymeleaf - Board (0) | 2022.10.17 |
Thymeleaf - maven install (0) | 2022.10.17 |
Tymeleaf 구조알기 (0) | 2022.10.17 |
thymeleaf - hello (연산, 문자열, 반복문,if) (0) | 2022.10.14 |
Comments