最新下载
热门教程
- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
- 10
bbs的数据结构和存储过程(一)
时间:2022-07-02 23:22:24 编辑:袖梨 来源:一聚教程网
/****************************************************************************/
/* */
/* FileName: bbs.sql */
/* */
/* Description: bbs数据结构 */
/* */
/* Table: */
/* */
/* Procedure: */
/* */
/* Author: bigeagle http://bigeagle.y**e*ah.net */
/* */
/* Date: 2001/1/29 */
/* */
/* History: */
/* */
/****************************************************************************/
/*数据结构*/
/*bbs用户表*/
if exists(select * from sysobjects where id = object_id('BBSUser'))
drop table BBSUser
go
create table BBSUser
(
id int identity primary key ,
UserName varchar(20) default '' not null ,
Password varchar(10) default '' not null ,
Email varchar(100) default '' not null ,
Homepage varchar(150) default '' not null ,
Signature varchar(255) default '' not null ,
SignDate datetime default getdate() not null ,
Point int default 0 not null
)
go
create index ix_bbsuser on bbsuser (id , username , password)
/*bbs表情表*/
if exists(select * from sysobjects where id = object_id('Face'))
drop table Face
go
create table Face
(
id tinyint identity primary key ,
Face varchar(30) default '' not null
)
go
/*bbs表*/
if exists(select * from sysobjects where id = object_id('BBS'))
drop table BBS
go
create table BBS
(
id int identity primary key ,
RootID int default 0 not null , --根ID
FatherID int default 0 not null , --父ID
Layer tinyint default 0 not null , --层
OrderNum float(53) default 0 not null , --排序基数
UserID int default 0 not null , --发言人ID
ForumID tinyint default 1 not null , --版面ID
Subject varchar(255) default '' not null , --主题
Content text default '' not null , --内容
FaceID tinyint default 1 not null , --表情
Hits int default 0 not null , --点击数
IP varchar(20) default '' not null , --发贴IP
/* */
/* FileName: bbs.sql */
/* */
/* Description: bbs数据结构 */
/* */
/* Table: */
/* */
/* Procedure: */
/* */
/* Author: bigeagle http://bigeagle.y**e*ah.net */
/* */
/* Date: 2001/1/29 */
/* */
/* History: */
/* */
/****************************************************************************/
/*数据结构*/
/*bbs用户表*/
if exists(select * from sysobjects where id = object_id('BBSUser'))
drop table BBSUser
go
create table BBSUser
(
id int identity primary key ,
UserName varchar(20) default '' not null ,
Password varchar(10) default '' not null ,
Email varchar(100) default '' not null ,
Homepage varchar(150) default '' not null ,
Signature varchar(255) default '' not null ,
SignDate datetime default getdate() not null ,
Point int default 0 not null
)
go
create index ix_bbsuser on bbsuser (id , username , password)
/*bbs表情表*/
if exists(select * from sysobjects where id = object_id('Face'))
drop table Face
go
create table Face
(
id tinyint identity primary key ,
Face varchar(30) default '' not null
)
go
/*bbs表*/
if exists(select * from sysobjects where id = object_id('BBS'))
drop table BBS
go
create table BBS
(
id int identity primary key ,
RootID int default 0 not null , --根ID
FatherID int default 0 not null , --父ID
Layer tinyint default 0 not null , --层
OrderNum float(53) default 0 not null , --排序基数
UserID int default 0 not null , --发言人ID
ForumID tinyint default 1 not null , --版面ID
Subject varchar(255) default '' not null , --主题
Content text default '' not null , --内容
FaceID tinyint default 1 not null , --表情
Hits int default 0 not null , --点击数
IP varchar(20) default '' not null , --发贴IP
相关文章
- 如何用AI制作圆锥效果海报 03-25
- 拷贝漫画如何实现在线漫画下拉式 03-25
- 蚂蚁森林神奇海洋2026年3月24日答案 03-25
- 歪漫科技无删减漫画免费下载最新版本-搜索到的不一定能看在线安装入口 03-25
- Excel打印怎样使每一页都有标题行 03-25
- 千牛网页版客服系统官网链接是什么 03-25