表名:ZL_Chat_Msg












序号列名数据类型长度小数位标识主键外键允许空默认值说明
1IDint40   
2UserIDnvarchar500     
3UserNamenvarchar1000    真名
4UserFacenvarchar1000    发消息的人的头像
5ReceUservarchar5000    接收人
6Contentntext160    消息内容
7CDatedatetime83     
8MsgTypeint40    消息类型

简要说明:

聊天记录表

Go
CREATE TABLE [dbo].[ZL_Chat_Msg](
[ID] [int] IDENTITY(1,1) NOT NULL,
[UserID] [nvarchar](50) NULL,
[UserName] [nvarchar](100) NULL,
[UserFace] [nvarchar](100) NULL,
[ReceUser] [varchar](500) NULL,
[Content] [ntext] NULL,
[CDate] [datetime] NULL,
[MsgType] [int] NULL,
CONSTRAINT [PK_ZL_Chat_Msg] PRIMARY KEY CLUSTERED
(
[ID] ASC
)WITH (PAD_INDEX  = OFF, STATISTICS_NORECOMPUTE  = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS  = ON, ALLOW_PAGE_LOCKS  = ON) ON [PRIMARY]
) ON [PRIMARY] TEXTIMAGE_ON [PRIMARY]

--注意:将清空全表数据

detele from ZL_Chat_Msg

--注意:将删除整个表

drop table ZL_Chat_Msg

--注意:清空且复位表ID序列为初始值

TRUNCATE table ZL_Chat_Msg