9.插入數(shù)據(jù) insert into 表名 values(值) insert into 表名(列名1……) values(值1……) 標(biāo)識(shí)列不用插入值 10.刪除語句(兩種方法) delete from 表名 where 列名=值 truncate table 表名
11.查詢的語法 select * from 表名 12.查詢姓張的學(xué)生 select * from student where name like ‘張%’ 13.查詢郵箱為空的 select * from student where email is null 14.在數(shù)據(jù)庫中,電話使用什么類型存儲(chǔ) varchar(50) char(2) 15.平均數(shù),求和,最大值,最小值,計(jì)數(shù) avg() sum() max() min() count() 16.模糊查詢中%和下劃線分別代表什么? %多個(gè)字符 _一個(gè)字符
17.學(xué)生表和年級(jí)表的連接查詢 select * form Student s ,grade g where s.gradeid = g.grdeid
select * from student s join grade g on s.gradeid = g.grdeid
18.聲明int和String 類型的變量 int num = 0; String name = “趙鐵蛋”; 19.聲明一個(gè)boolean類型并且賦值 boolean flag = true; boolean flag = false; 20.變量的命名規(guī)則與規(guī)范 $ _ 字母+數(shù)字 $ _ 字母
21.如果成績(jī)大于80,大于60,大于30各怎么樣
public static void main(String []args){Scanner sc = new Scanner(System.in);System.out.println("請(qǐng)輸入成績(jī):");int score = sc.nextInt();if(score>80){優(yōu)秀}else if(score>60){良好}else if(score>30){不行}a = 10; b=11;if(true){a++;}else{a--;}輸出a和b的值:}