# 刪除觸發器代碼
drop trigger 觸發器名;# 當一個學員發生轉班,班級對應的總數進行同步變化# 當一個學員發生轉班,班級對應的總數進行同步變化delimiter !!create trigger movestudent after update on stu1 for each ROWBEGIN#定義兩個變量declare numOld int; # 定義舊班級人數declare numNew int; # 定義新班級人數set numOld = (select stu_num from stu2 where class = old.class);select numOld into @a;set numNew = (select stu_num from stu2 where class = new.class);select numNew into @b;update stu2 set stu_num = numOld - 1 where class = old.class;update stu2 set stu_num = numNew + 1 where class = new.class;end !!
delimiter;update stu1 set class = 2302 where name = "阿濤";select @a;
select @b;drop trigger movestudent;
# 創建視圖表
create view 視圖名稱 as select 已查詢語句;# 查詢當前數據庫所有的視圖
create view stu_2301 as
select * from stu1 where class = 2301;# 刪除視圖表
drop view 視圖名稱;# 查詢當前數據庫所有視圖
# 格式
show full tables in 數據庫名稱 where table_type like "view";show full tables in demo924 where table_type like "view";
解題思路:
方法一:暴力
class Solution {public int maxProduct(int[] nums) {int max Integer.MIN_VALUE;int s 1;for (int i 0; i < nums.length; i) {s 1;for (int j i ; j < nums.length; j) {s * nums[j];max Math.max(max, s);}}ret…
Where can I catch a taxi?哪里我可以叫到出租車?
The taxi zone is right on the left corner over there.出租車站臺就在左邊轉角處。
Are you free?您有空嗎? Sure. Where are you going?當然。您要去哪里?
Drive me back to Santa …
有些場景可能kamdbctl create不好使,可能需要手工創建 kamailio database tables,可參考下面的命令序列: USE mysql # 刪除之前創建的用戶 SELECT user,host FROM user; DROP USER kamailio%; FLUSH PRIVILEGES; # 刪除之前創建的數據庫 DROP…