08 2022 档案
摘要:-- 查询姓刘的同学 -- like 结合 %(表示0到任意个字符) _(表示一个字符) select `studentNo`, `studentName` from student where studentName LIKE '刘%' -- 查询姓刘的同学后面分别只有一个字的,两个字的 sele
阅读全文
摘要:增:insert into `table` (`id`,`name`,`sex`,`grade`) value('1','张三','男','三年级') 删:delete from `table` where `id` = '1' 改:update 'table' set `name` = '李四'
阅读全文
摘要:相同点:1,都能删除表数据,都不会删除表结构 不同点: 1,delete删除表数据时自增不归零,truncate清空表自增归零,重新设置自增列 2,truncate清空表数据不会影响事务 拓展:delete删除的问题,重启数据库现象 innoDB自增列会从1开始(数据存在内存中,断电即失) MyIA
阅读全文
浙公网安备 33010602011771号