序号 | 列名 | 数据类型 | 长度 | 小数位 | 标识 | 主键 | 外键 | 允许空 | 默认值 | 说明 |
1 | ID | int | 4 | 0 | 是 | 是 | 否 | |||
2 | UserID | nvarchar | 50 | 0 | 是 | |||||
3 | UserName | nvarchar | 100 | 0 | 是 | 真名 | ||||
4 | UserFace | nvarchar | 100 | 0 | 是 | 发消息的人的头像 | ||||
5 | ReceUser | varchar | 500 | 0 | 是 | 接收人 | ||||
6 | Content | ntext | 16 | 0 | 是 | 消息内容 | ||||
7 | CDate | datetime | 8 | 3 | 是 | |||||
8 | MsgType | int | 4 | 0 | 是 | 消息类型 |
聊天记录表
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
TRUNCATE table ZL_Chat_Msg