create table body
{
   postid int unsigned not null primary key,
   message text
}grant select, insert, update, delete 
on discussion.*
to discussion@localhost identified by 'password';这段数据库 源码什么意思 
有的地方 看不懂??

解决方案 »

  1.   

    [code=SQL]create table body  #创建body数据表
    {
      postid int unsigned not null primary key,  #postid字段无符号整数类型,声明为主键
      message text  #message字段,TEXT文本类型
    }/*创建discussion用户,只允许从本机(localhost)访问discussion数据库,密码为password
    并且只能对该数据库进行SELECT、INSERT、UPDATE、DELETE操作*/
    grant select, insert, update, delete on discussion.* to discussion@localhost identified by 'password';[/code]
      

  2.   

    create table body  #创建body数据表
    {
      postid int unsigned not null primary key,  #postid字段无符号整数类型,声明为主键
      message text  #message字段,TEXT文本类型
    }/*创建discussion用户,只允许从本机(localhost)访问discussion数据库,密码为password
    并且只能对该数据库进行SELECT、INSERT、UPDATE、DELETE操作*/
    grant select, insert, update, delete on discussion.* to discussion@localhost identified by 'password';
      

  3.   

     postid int unsigned not null primary key,  #postid字段无符号整数类型,声明为主键 补充不允许空值not null,不过这里主键的再设置这个有点多余了!