一、
1.查看B( pre_forum_thread )最大tid 1
SELECT max(tid) as x FROM pre_forum_thread
2.查看B( pre_forum_post)最大pid
SELECT max(pid) as y FROM pre_forum_post 1
3.查看B( pre_forum_threadclass)最大typeidX 1
SELECT max(typeid) as typeidX FROM pre_forum_threadclass
4.查看B( pre_forum_forum )最大fid 1
SELECT max(fid) as f_x FROM pre_forum_forum
5.查看B( pre_forum_forum )最大fid 35
SELECT max(fid) as f_x FROM pre_forum_forum
5.更新
a.更新A( pre_forum_thread )tid
UPDATE pre_forum_thread SET tid=tid+x
b.更新A( pre_forum_post )tid
UPDATE pre_forum_post SET tid=tid+x
c.更新A( pre_forum_post )pid
UPDATE pre_forum_post SET pid=pid+y
d.更新A( pre_forum_threadclass )typeid
UPDATE pre_forum_threadclass SET typeid=typeid+typeidX
e.更新A( pre_forum_threadclass )fid
UPDATE pre_forum_threadclass SET fid=fid+y
f.更新A( pre_forum_forum )fid
UPDATE pre_forum_forum SET fid=fid+f_x
UPDATE pre_forum_post SET pid=pid+f_x
UPDATE pre_forum_thread SET pid=pid+f_x
6.两表合并
insert into `8086`.pre_forum_thread select * from pre_forum_thread
insert into `8086`.pre_forum_post select * from pre_forum_post
insert into `8086`.pre_forum_threadclass select * from pre_forum_threadclass
insert into `8086`.pre_forum_threadclass select * from pre_forum_forum