代码拉取完成,页面将自动刷新
ALTER TABLE person1 ADD sex VARCHAR(10);
SELECT * FROM person1;
ALTER TABLE person1 DROP sex;
ALTER TABLE person1 CHANGE sex sexx INT;
ALTER TABLE person1 MODIFY sexx VARCHAR(20);
ALTER TABLE person1 ALTER sexx SET DEFAULT '性别';
ALTER TABLE person1 ALTER age SET DEFAULT 18;
ALTER TABLE person1 RENAME person2;
SELECT * FROM person2;
ALTER TABLE person2 RENAME person1;
SELECT INDEX FROM person1;
CREATE VIEW personview AS SELECT NAME FROM person1;
SELECT * FROM personview;
CREATE VIEW personview2(stuname,stuno) AS SELECT NAME,id FROM person1;
SELECT * FROM personview2;`person1`
CREATE OR REPLACE VIEW personview2(NAME,noo) AS SELECT NAME,id FROM person1;
CREATE FORCE VIEW view1 AS SELECT * FROM person WITH CHECK OPTION;
CREATE INDEX index1 ON person1(NAME);
SELECT * FROM person1 WHERE NAME='ben';
ALTER TABLE person1 DROP id;
ALTER TABLE person1 ADD id INT UNSIGNED NOT NULL AUTO_INCREMENT FIRST,ADD PRIMARY KEY(id);
SELECT DISTINCT age,id FROM person1;
UPDATE person1 SET age=26 WHERE NAME='ben';
SELECT * FROM person1 LIMIT 3,3;
SELECT NAME FROM person UNION SELECT NAME FROM person1 ORDER BY NAME;
EXPLAIN SELECT * FROM person1;
EXPLAIN`person1`SELECT * FROM person WHERE age>20;
SELECT * FROM course;
EXPLAIN SELECT tc.tcdesc FROM teacherCard tc WHERE tc.tcid =
(SELECT t.tcid FROM teacher t WHERE t.tid =
(SELECT c.tid FROM course c WHERE c.cname = 'sql')
);
EXPLAIN SELECT cr.cname FROM ( SELECT * FROM course WHERE tid = 1 UNION SELECT * FROM course WHERE tid = 2 ) cr ;
INSERT INTO teacher VALUES(4,'tz',4) ;
INSERT INTO teacherCard VALUES(4,'tz222');
ALTER TABLE teacher ADD INDEX index_name (tname) ;
EXPLAIN SELECT * FROM teacher WHERE tname = 'tz';
DESC teacher;
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。