myid myfield mytext
101 3 text1
120 3 text2
210 3 text4
428 3 text19
101 5
118 5
210 5
120 5请问,在php 5 + mysql 4中,如何实现把myfield为3 的mytext内容复制到myfield为5的mytext中,要求myid必须对应。例如,把 text4 复制到 where myid=210 and myfield=5 的 mytext字段。myfield为3和5的myid不一定完全一致的,例如,那个myid 428
101 3 text1
120 3 text2
210 3 text4
428 3 text19
101 5
118 5
210 5
120 5请问,在php 5 + mysql 4中,如何实现把myfield为3 的mytext内容复制到myfield为5的mytext中,要求myid必须对应。例如,把 text4 复制到 where myid=210 and myfield=5 的 mytext字段。myfield为3和5的myid不一定完全一致的,例如,那个myid 428
update mytable a,mytable b
set a.mytext=b.mytext
whree a.myid=b.myid and a.myfield=5 and b.myfield=3;