Konuyu Oyla:
  • Toplam: 0 Oy - Ortalama: 0
  • 1
  • 2
  • 3
  • 4
  • 5
genel-mysqlde bir tablodaki bir yazıyı bulup değiştirme.
#1
Search and Replace in MySQL database with phpMyAdmin

Do a search and replace in any MySQL database in phpMyAdmin. You do not need to download the database export at all, just run this simple command. This also works through the MySQL command line.

To search and replace a text string, start up phpMyAdmin, and click on your database name that you want to run the search and replace through. At the top of the window, click on the "SQL" tab.

In the text box, enter the following code. This is the generic setup, so edit to satisfy your needs:
UPDATE tablename SET tablefield = replace(tablefield,"findstring","replacestring");

You can add a WHERE clause onto this as well.

For example, here is one command a ran:
UPDATE `mos2_content` SET introtext = replace(introtext,"<p>","") WHERE `title` REGEXP '-0';

This got rid of all paragraph tags in the mos2_content table where the title included the string "-0".

Hope this helps. If you have any comments, suggestions, questions, or your own code, please submit a comment below.
Ara
Cevapla
#2
bu phpbb yi düzeltmek için şunu kullandım:

UPDATE `forum2_phpbb3_posts` SET post_subject = replace(post_subject,"ք±","ı");
UPDATE `forum2_phpbb3_posts` SET post_subject = replace(post_subject,"քş¸","ğ");
UPDATE `forum2_phpbb3_posts` SET post_subject = replace(post_subject,"օş¸","ş");
UPDATE `forum2_phpbb3_posts` SET post_subject = replace(post_subject,"փ§","ç");
UPDATE `forum2_phpbb3_posts` SET post_subject = replace(post_subject,"փ¼","ü");
UPDATE `forum2_phpbb3_posts` SET post_subject = replace(post_subject,"փ¶","ö");
UPDATE `forum2_phpbb3_posts` SET post_subject = replace(post_subject,"ք°","İ");


UPDATE `forum2_phpbb3_posts` SET post_text = replace(post_text,"ք±","ı");
UPDATE `forum2_phpbb3_posts` SET post_text = replace(post_text,"քş¸","ğ");
UPDATE `forum2_phpbb3_posts` SET post_text = replace(post_text,"օş¸","ş");
UPDATE `forum2_phpbb3_posts` SET post_text = replace(post_text,"փ§","ç");
UPDATE `forum2_phpbb3_posts` SET post_text = replace(post_text,"փ¼","ü");
UPDATE `forum2_phpbb3_posts` SET post_text = replace(post_text,"փ¶","ö");
UPDATE `forum2_phpbb3_posts` SET post_text = replace(post_text,"ք°","İ");
Ara
Cevapla


Hızlı Menü:


Şu anda bu konuyu okuyanlar: 1 Ziyaretçi


10tl.net Destek Forumu -

Online Shopping App
Online Shopping - E-Commerce Platform
Online Shopping - E-Commerce Platform
Feinunze Schmuck Jewelery Online Shopping