99999久久久久久亚洲,欧美人与禽猛交狂配,高清日韩av在线影院,一个人在线高清免费观看,啦啦啦在线视频免费观看www

熱線電話:13121318867

登錄
2023-08-11 閱讀量: 1922
CDA數(shù)據(jù)分析一級(jí)教材SQL語(yǔ)句 05

3.DML


-- 指定字段名添加

insert into dept(depid,depname,peoplecount)values('p10’,’人力部’,,15),(‘p20’,’研發(fā)部’,50);

-- 不指定字段名添加

insert into dept values

('p10’,’人力部’,15),(‘p20',’研發(fā)部’,50);


-- 查看默認(rèn)安全路徑

show variables like ‘%secure%'



-- 為 Monthly Indicator 表導(dǎo)入外部 txt 文件

load data infile ‘c:/ProgramData/MySQL/MySQL Server 8.0/Uploads/xx.txt'

into table Monthly Indicator


fields terminated by ‘\ t’

[ignore l lines];


-- 檢查導(dǎo)入內(nèi)容 Monthly Indicator

select * from Monthly Indicator;

-- 檢查導(dǎo)入數(shù)據(jù)總行數(shù) Monthly Indicator

select count(x) from Monthly Indicator;

-- 檢查表結(jié)構(gòu)

desc Monthly Indicator;


--將部門 ID為 p01的信息單獨(dú)保存到 department 表中

create table department as

select depid,depname,peoplecount

from dept

where depid='p01';


-- 將 dept 表中編號(hào)為 p11 的部門名稱修改為后勤部

update dept set depname='后勤部 where depid='p11';


-- 刪除 p20 部門的員工記錄

delete from dept where depid=p20;

-- 刪除所有的員工記錄

delete from dept;

truncate dept;


0.0000
0
關(guān)注作者
收藏
評(píng)論(0)

發(fā)表評(píng)論

暫無(wú)數(shù)據(jù)
推薦帖子