為企業提供網站平臺解決方案

178 7892 1916

QQ客服:點擊這里給我發消息 點擊這里給我發消息

最新動態:

DeDeCMS教程

你的位置:中国竞彩足球比分网 > 建站知識 > DeDeCMS教程 > dede怎么批量修改前綴,dedecms批量替換表前綴

竞彩足球比分装备:dede怎么批量修改前綴,dedecms批量替換表前綴

發布時間:2013-04-17 09:44作者:中国竞彩足球比分网網址:中国竞彩足球比分网瀏覽:次
安裝DedeCMS的時候,數據表前綴默認為dede_,當系統使用了一段時間后,想更改數據表前綴,結果發現不是那么容易。有沒有批量修改表前綴的方法?
安裝DedeCMS的時候,數據表前綴默認為dede_,當系統使用了一段時間后,想更改數據表前綴,結果發現不是那么容易。有沒有批量修改表前綴的方法?
在phpmyadmin執行如下SQL命令,將表前綴轉換。。如果還有表沒轉換可以跟著這個格式添加。。。

1)復制我提供的數據另存為DEDE-RENAME.BAT文件。
2)用記事本打開DEDE-RENAME.BAT文件,采用文字替換(CTRL+H),將" weihu"(請注意在weihu前面有一個空格)替換成" xxx"(請注意在XXX前面有一個空格)。
3)然后將該文件拷貝到服務器相應的MYSQL數據庫目錄中,停止MYSQL服務/IIS服務,運行該程序,即可批量修改表前綴了。
4)修改好表前綴后,需要修改/DATA/COMMON.INC.PHP文件中的$cfg_dbprefix = 'dede_'。以及對后臺中的“頻道模型”-->“內容模型管理”中的相應的附加表也做一下修改。 

ALTER TABLE qq_addonimages RENAME TO dede_addonimages;
ALTER TABLE qq_addoninfos RENAME TO dede_addoninfos;
ALTER TABLE qq_admin RENAME TO dede_admin;
ALTER TABLE qq_admintype RENAME TO dede_admintype;
ALTER TABLE qq_advancedsearch RENAME TO dede_advancedsearch;
ALTER TABLE qq_arcatt RENAME TO dede_arcatt;
ALTER TABLE qq_arccache RENAME TO dede_arccache;
ALTER TABLE qq_archives RENAME TO dede_archives;
ALTER TABLE qq_arcmulti RENAME TO dede_arcmulti;
ALTER TABLE qq_arcrank RENAME TO dede_arcrank;
ALTER TABLE qq_arctiny RENAME TO dede_arctiny;
ALTER TABLE qq_arctype RENAME TO dede_arctype;
ALTER TABLE qq_area RENAME TO dede_area;
ALTER TABLE qq_channeltype RENAME TO dede_channeltype;
ALTER TABLE qq_co_htmls RENAME TO dede_co_htmls;
ALTER TABLE qq_co_mediaurls RENAME TO dede_co_mediaurls;
ALTER TABLE qq_co_note RENAME TO dede_co_note;
ALTER TABLE qq_co_onepage RENAME TO dede_co_onepage;
ALTER TABLE qq_co_urls RENAME TO dede_co_urls;
ALTER TABLE qq_diyforms RENAME TO dede_diyforms;
ALTER TABLE qq_downloads RENAME TO dede_downloads;
ALTER TABLE qq_erradd RENAME TO dede_erradd;
ALTER TABLE qq_feedback RENAME TO dede_feedback;
ALTER TABLE qq_flink RENAME TO dede_flink;
ALTER TABLE qq_flinktype RENAME TO dede_flinktype;
ALTER TABLE qq_freelist RENAME TO dede_freelist;
ALTER TABLE qq_homepageset RENAME TO dede_homepageset;
ALTER TABLE qq_keywords RENAME TO dede_keywords;
ALTER TABLE qq_log RENAME TO dede_log;
ALTER TABLE qq_member RENAME TO dede_member;
ALTER TABLE qq_member_company RENAME TO dede_member_company;
ALTER TABLE qq_member_feed RENAME TO dede_member_feed;
ALTER TABLE qq_member_flink RENAME TO dede_member_flink;
ALTER TABLE qq_member_friends RENAME TO dede_member_friends;
ALTER TABLE qq_member_group RENAME TO dede_member_group;
ALTER TABLE qq_member_guestbook RENAME TO dede_member_guestbook;
ALTER TABLE qq_member_model RENAME TO dede_member_model;
ALTER TABLE qq_member_msg RENAME TO dede_member_msg;
ALTER TABLE qq_member_operation RENAME TO dede_member_operation;
ALTER TABLE qq_member_person RENAME TO dede_member_person;
ALTER TABLE qq_member_pms RENAME TO dede_member_pms;
ALTER TABLE qq_member_snsmsg RENAME TO dede_member_snsmsg;
ALTER TABLE qq_member_space RENAME TO dede_member_space;
ALTER TABLE qq_member_stow RENAME TO dede_member_stow;
ALTER TABLE qq_member_stowtype RENAME TO dede_member_stowtype;
ALTER TABLE qq_member_tj RENAME TO dede_member_tj;
ALTER TABLE qq_member_type RENAME TO dede_member_type;
ALTER TABLE qq_member_vhistory RENAME TO dede_member_vhistory;
ALTER TABLE qq_moneycard_record RENAME TO dede_moneycard_record;
ALTER TABLE qq_moneycard_type RENAME TO dede_moneycard_type;
ALTER TABLE qq_mtypes RENAME TO dede_mtypes;
ALTER TABLE qq_multiserv_config RENAME TO dede_multiserv_config;
ALTER TABLE qq_myad RENAME TO dede_myad;
ALTER TABLE qq_mytag RENAME TO dede_mytag;
ALTER TABLE qq_plus RENAME TO dede_plus;
ALTER TABLE qq_pwd_tmp RENAME TO dede_pwd_tmp;
ALTER TABLE qq_ratings RENAME TO dede_ratings;
ALTER TABLE qq_scores RENAME TO dede_scores;
ALTER TABLE qq_search_cache RENAME TO dede_search_cache;
ALTER TABLE qq_search_keywords RENAME TO dede_search_keywords;
ALTER TABLE qq_sgpage RENAME TO dede_sgpage;
ALTER TABLE qq_shops_delivery RENAME TO dede_shops_delivery;
ALTER TABLE qq_shops_orders RENAME TO dede_shops_orders;
ALTER TABLE qq_shops_products RENAME TO dede_shops_products;
ALTER TABLE qq_shops_userinfo RENAME TO dede_shops_userinfo;
ALTER TABLE qq_softconfig RENAME TO dede_softconfig;
ALTER TABLE qq_stepselect RENAME TO dede_stepselect;
ALTER TABLE qq_sys_enum RENAME TO dede_sys_enum;
ALTER TABLE qq_sys_module RENAME TO dede_sys_module;
ALTER TABLE qq_sys_set RENAME TO dede_sys_set;
ALTER TABLE qq_sys_task RENAME TO dede_sys_task;
ALTER TABLE qq_sysconfig RENAME TO dede_sysconfig;
ALTER TABLE qq_tagindex RENAME TO dede_tagindex;
ALTER TABLE qq_taglist RENAME TO dede_taglist;
ALTER TABLE qq_uploads RENAME TO dede_uploads;
ALTER TABLE qq_verifies RENAME TO dede_verifies;
ALTER TABLE qq_vote RENAME TO dede_vote;
ALTER TABLE qq_addonarticle RENAME TO dede_addonarticle;