求教replace的写法
REPLACE   waterman   SET   threads   =   `threads`+1   SELECT   threads   WHERE   forumid   =   1   and   user   =    'test '   
 我的意思是,1.如果不存在forumid=1   and   user= 'test '主键的记录,则插入threads取默认值加1 
 2.如果存在forumid=1   and   user= 'test '主键的记录,threads取已有值加1   
 谢谢!
------解决方案--------------------on duplicate 指的是如果有重复的才更新。