--SQL SERVER生成测试环境: Create database Test; go USE [Test] GO if OBJECT_ID('Tab','U') is not null drop table Tab go CREATE TABLE [dbo].[Tab]( [ID] [int] NOT NULL CONSTRAINT [PK_Tab] PRIMARY KEY CLUSTERED , [name] [sysname] NOT NULL ) --打开Visual Studio—创
from_unixtime(unix_timestamp, format) 把时间戳转化为指定的格式 as: select from_unixtime(addTime, '%Y-%m-%d %h:%i:%s') as datetime from table1 unix_timestamp([datetime]) 把日期时间转化为时间戳 as: select from_unixtime([addDay]) as unixtime from table1 case(value as type) co