728x90

02_Database 16

06_데이터 수정(UPDATE)

데이터 수정(UPDATE)01. UPDATE문의 기본 문법 update 테이블이름 set 열1 = 값1, 열2 = 값2... where 조건;  city_popul 테이블의 도시 이름 중에서 'Seoul'을 '서울'로 변경하기select * from city_popul where city_name = 'Seoul';update city_popul set city_name = '서울' where city_name = 'Seoul'; select * from city_popul where city_name = '서울'; 02. 한꺼번에 여러 열 변경하기 도시이름 New York을 뉴욕으로 바꾸면서 인구는 0으로 수정update city_popul set city_name = '뉴욕', population =..

02_Database 2025.01.29

05_데이터 입력(INSERT)

데이터 입력(INSERT)01. INSERT문의 기본 문법insert into 테이블 (열1, 열2, 열3......) values (값1, 값2, 값3......); ※주의점테이블 이름 다음에 나오는 열은 생략 가능함다만, 생략할 시에는 values다음에 나오는 값들의 순서와 개수는 열의 순서 및 개수와 동일해야 함create table toy_shop (toy_id int, toy_name char(4), age int); -- INSERT연습용 테이블 작성 select * from toy_shop;insert into toy_shop values (1, '우디', 25); 아이디와 이름만 입력하고, 나이는 입력하고 싶지 않다면insert into toy_shop (toy_id, toy_name) v..

02_Database 2025.01.29

04_데이터 조회(SELECT)

데이터 조회(SELECT문) 01. use문 사용할 데이터베이스를 지정use market_db; 02. DMLDML(Data Manipulation Language, 데이터 조작어) DML의 종류 SELECT: 데이터를 조회INSERT: 데이터를 삽입UPDATE: 데이터를 수정DELETE: 데이터를 삭제 03. SELECT문의 기본 형식select (열이름)from (테이블 이름)where (조건식)group by (열 이름)having (조건식)order by (열 이름)limit 숫자;  SELECT문은 키워드에 의해 구분되어 여러 개의 절로 구성됨SELECT ~ FROM ~select * from member; ● select: 테이블에서 데이터를 가져올 때 사용하는 예약어 ● *: asterisk..

02_Database 2025.01.21

02_DBeaver 다운로드 및 설치

DBeaver 다운로드 및 설치01. 이하 URL에 접속https://dbeaver.io/ DBeaver Community | Free Universal Database ToolDBeaver Universal Database Tool DBeaver Community is a free cross-platform database tool for developers, database administrators, analysts, and everyone working with data. It supports all popular SQL databases like MySQL, MariaDB, PostgreSQL, SQLite, Apachdbeaver.io 02. 필자의 운영체제는 Windows이므로, Downlo..

02_Database 2025.01.21

01_Mysql 다운로드 및 설치

Mysql 다운로드 및 설치 01. 이하 URL에 접속 https://www.mysql.com/ MySQLOver 2000 ISVs, OEMs, and VARs rely on MySQL as their products' embedded database to make their applications, hardware and appliances more competitive, bring them to market faster, and lower their cost of goods sold. Learn More »www.mysql.com 02. DOWNLOADS를 클릭  03. MySQL Community (GPL) Downloads » 를 클릭   04. 필자의 운영체제는 Windows이므로, 「Mysql..

02_Database 2025.01.20
728x90