mysql 5.5 でこれを行うにはどうすればよいですか? concatを考えていましたが、もっと簡単なものがあると思います。
id content
1
2
update posts set content='here is content ' + this.id
となることによって:
id content
1 here is content 1
2 here is content 2
どうも
mysql 5.5 でこれを行うにはどうすればよいですか? concatを考えていましたが、もっと簡単なものがあると思います。
id content
1
2
update posts set content='here is content ' + this.id
となることによって:
id content
1 here is content 1
2 here is content 2
どうも
これはあなたが必要とすることをします:
update posts
set content=CONCAT('here is content ', CAST(id as CHARACTER))
これは、SQLFiddle のテストへのリンクです。
私は推測する:
update comment set comment=concat('here is a comment: ', id,' these are other things');