常用sql语句

SELECT * FROM information_schema.innodb_trx; ##找到卡死的进程id并杀掉
kill 817;
kill 818;

insert into hisdb.forecast_three_solar_origin_weather (date,tmp,irradiance,humid,precipitation,wind_direction,wind_speed,update_time,id,dtype,mode) values ('2025-9-10 00:00:00','cty','cty','cty','1','cty','1','2024-01-30 11:12:21.831054','160832050000228951','0','0'),('2025-9-10 00:15:00','cty','cty','cty','1','cty','1','2024-01-30 11:12:21.831054','160832050000228951','0','0');

select * from hisdb.forecast_three_solar_origin_weather where id='160832050000228951' and date between '2023-9-10 00:00:00' and '2023-9-10 00:15:00';

select * from hisdb.forecast_three_solar_config_object_predict where id='160832050000323913';


select * from hisdb.forecast_three_solar_clean_load where id='160832050000228955' and date between '2023-01-01' and '2023-01-02';


ALTER TABLE hisdb.forecast_three_solar_origin_weather DROP COLUMN windspeed;

UPDATE user_table SET tel='88888888';
INSERT INTO table_name (column1, column2, column3, ...) VALUES (value1, value2, value3, ...);
delete from hisdb.forecast_three_solar_clean_weather WHERE (id='160832050000228951' and date BETWEEN '2023-08-10 00:00:00' AND '2024-08-10 00:00:00');
posted @ 2023-12-28 11:44  笨笨和呆呆  阅读(3)  评论(0)    收藏  举报