[Spring Boot] 13. 스프링부트 상점 v1 (4) 더미데이터 세팅

김주희's avatar
Mar 18, 2025
[Spring Boot] 13. 스프링부트 상점 v1 (4) 더미데이터 세팅
❗
더미데이터는 일관성 있게 만들어야 된다!
⇒ 바나나와 딸기의 재고를 50/50으로 해두면 원래 바나나와 딸기는 60/55인 걸로 생각하게 됨
 
notion image
 
insert into store_tb(name, stock, price) values('바나나', 40, 3000); insert into store_tb(name, stock, price) values('딸기', 45, 2000); insert into log_tb(store_id, qty, total_price, buyer) values(1, 5, 15000, 'ssar'); insert into log_tb(store_id, qty, total_price, buyer) values(1, 5, 15000, 'ssar'); insert into log_tb(store_id, qty, total_price, buyer) values(2, 5, 10000, 'cos');
 

2. application run 후 h2-console로 확인하기

notion image
notion image
Share article