CREATETABLEdynamic(idINT(11)UNSIGNEDNOTNULLAUTO_INCREMENT,zidINT(11)UNSIGNEDNOTNULLcomment'任务id',jjidINT(11)UNSIGNEDNOTNULLcomment'发任务人id',jidINT(11)UNSIGNEDNOTNULL...
CREATE TABLE dynamic (
id INT(11) UNSIGNED NOT NULL AUTO_INCREMENT,
zid INT(11) UNSIGNED NOT NULL comment '任务id',
jjid INT(11) UNSIGNED NOT NULL comment '发任务人id',
jid INT(11) UNSIGNED NOT NULL DEFAULT 0 comment '接任务id',
isok SMALLINT(1) default 0 comment '任务完成情况,0表示未完成,2表示解除',
nowtime int unsigned default 1 comment '互动时间'
)
复制代码
CREATE TABLE IF NOT EXISTS lwb(
zid int not null primary key auto_increment,
jjid int not null comment '发布人id',
zfkql tinyint default 0 comment '金额',
zxhyq tinyint default 0 comment '任务星级要求',
zxhdq varchar(20) default '无' comment '任务限制地区,写省或自治市',
zxhls tinyint default 0 comment '任务链接数',
zxhlj varchar(150) default 'no' comment '任务链接',
zlwyj DECIMAL(5,2) not null comment '任务佣金',
zxhms text comment '任务描述',
zisj tinyint default 0 comment '是否被接0不是2完成',
zvip tinyint default 0 comment '是否vip任务0不是',
ztime int unsigned not null comment '发布时间',
zlwzl tinyint not null default 1 comment '任务种类',
rid int default 0 comment '接任务id,0没人接')
复制代码
如何能何得每个用户和任务发布人之间的交互时间,没有就无。之前接个任务就写入上一表交互时间。怎么关联查询任务,不同用户传看到自己各任务人交互时间,求大神
箭头位置所求是也
展开