--批量设置表中某字段为固定值 update dbo.LampList set LampGroupAddress=ISNULL(LampGroupAddress,'')+1 --批量设置表中某字段为Null UPDATE dbo.LampList SET LampAddress=NULL--批量删除ID大于1024DELETE FROM dbo.LampList WHERE Id>1024…
Mysql 常用 SQL 语句集锦 基础篇 //查询时间,友好提示 $sql = "select date_format(create_time, '%Y-%m-%d') as day from table_name"; //int 时间戳类型 $sql = "select from_unixtime(create_time, '%Y-%m-%d') as day from table_name"; //一个sql返回多个总数 $sql = "select…
Mysql 常用 SQL 语句集锦 基础篇 //查询时间,友好提示 $sql = "select date_format(create_time, '%Y-%m-%d') as day from table_name"; //int 时间戳类型 $sql = "select from_unixtime(create_time, '%Y-%m-%d') as day from table_name"; //一个sql返回多个总数 $sql = "select…