How to Find and Replace Text in MySQL Database using SQL कैसे को ढूँढें और बदलें पाठ MySQL डाटाबेस में एसक्यूएल प्रयोग

MySQL database has a handy and simple string function REPLACE() that allows table data with the matching string (from_string) to be replaced by new string (to_string). MySQL डाटाबेस का काम और आसान स्ट्रिंग समारोह REPLACE है () है कि मिलान (वाक्यांश from_string) को नया स्ट्रिंग (to_string) ने उसकी जगह ली के साथ तालिका डेटा की अनुमति देता है. This is useful if there is need to search and replace a text string which affects many records or rows, such as change of company name, postcode, URL or spelling mistake. यह उपयोगी है अगर वहाँ है कि खोज और एक पाठ स्ट्रिंग है जो कई रिकॉर्ड या पंक्तियाँ ऐसी कंपनी का नाम, पिन कोड, URL या वर्तनी की गलती के परिवर्तन के रूप में प्रभावित होता है, जगह की जरूरत है.

The syntax of REPLACE is REPLACE(text_string, from_string, to_string) REPLACE के वाक्यविन्यास REPLACE text_string (है, from_string, to_string)

MySQL reference MySQL संदर्भ describes REPLACE as function that returns the string text_string with all occurrences of the string from_string replaced by the string to_string, where matching is case-sensitive when searching for from_string. समारोह के रूप में REPLACE का वर्णन करता है कि रिटर्न from_string स्ट्रिंग to_string, जहां से मेल खाने वाले मामले के प्रति संवेदनशील जब from_string के लिए खोज रहा है की जगह तार की सभी घटनाओं के साथ तार text_string. text_string can be retrieved from the a field in the database table too. text_string डेटाबेस तालिका में एक क्षेत्र से भी लिया जा सकता है. Most SQL command can be REPLACE() function, especially SELECT and UPDATE manipulation statement. सबसे एसक्यूएल कमान REPLACE () समारोह में, विशेष रूप से चुनें और अद्यतन हेरफेर बयान हो सकता है.

For example: उदाहरण के लिए:

update TABLE_NAME set FIELD_NAME = replace(FIELD_NAME, 'find this string', 'replace found string with this string'); अद्यतन TABLE_NAME FIELD_NAME (FIELD_NAME, 'इस जगह =' स्ट्रिंग 'की जगह' इस तार से तार मिल पाया) स्थापित;

update client_table set company_name = replace(company_name, 'Old Company', 'New Company') client_table सेट = company_name जगह अद्यतन (company_name, 'पुराने' कंपनी ',' नई 'कम्पनी)

The above statement will replace all instances of 'Old Company' to 'New Company' in the field of company_name of client_table table. ऊपर बयान 'के सभी उदाहरणों का स्थान ले लेगा पुराने' कंपनी 'के लिए नई' कंपनी client_table तालिका के company_name के क्षेत्र में.

Another example: एक और उदाहरण:

SELECT REPLACE('www.mysql.com', 'w', 'Ww'); का चयन करें REPLACE '(' www.mysql.com ',' w ',' ww);

Above statement will return 'WwWwWw.mysql.com' as result. ऊपर बयान 'वापसी परिणाम' WwWwWw.mysql.com के रूप में होगा.

IMPORTANT : The page is machine translated and provided "as is" without warranty. महत्वपूर्ण: पृष्ठ की मशीन है और अनुवाद प्रदान "के रूप में वारंटी के बिना है." Machine translation may be difficult to understand. मशीन अनुवाद मुश्किल से समझ सकते हो. Please refer to कृपया उल्लेख करने original English article मूल अंग्रेजी लेख whenever possible. जब भी संभव है.


28 Responses to “How to Find and Replace Text in MySQL Database using SQL” 28 उत्तर के लिए "कैसे ढूँढें और बदलें पाठ MySQL डाटाबेस में एसक्यूएल प्रयोग"

Pages: [2] Pages: [2] 1 1 » » Show All सभी दिखाएँ

  1. timtak timtak
    October 28th, 2009 09:00 28 अक्टूबर 2009 09:00
    28 28

    I am looking for a way to do this globally accross a whole database. मैं एक तरह से यह एक संपूर्ण डेटाबेस भर में दुनिया भर में कर के लिए देख रहा हूँ.

  2. kevin केविन
    October 20th, 2009 20:28 20 अक्टूबर 2009 20:28
    27 27

    Doesn't work at all for replacing web addresses within a database. एक डेटाबेस के भीतर वेब पते के स्थान के लिए बिल्कुल काम नहीं है.

  3. vishwas vishwas
    September 30th, 2009 15:26 30 सितम्बर 2009 15:26
    26 26

    Wanted to use REPLACE command to use for a column of a table…and this helped me…thanks स्थानापन्न करने के लिए कमांड का प्रयोग कर एक टेबल के एक स्तंभ के लिए उपयोग ... और यह मेरी मदद की तलाश है ... धन्यवाद

Pages: [2] Pages: [2] 1 1 » » Show All सभी दिखाएँ

Leave a Reply एक उत्तर दें छोड़ दो

You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong> आप इन टैग्स: <a href="" उपयोग title=""> <abbr title=""> <acronym कर सकते हैं <blockquote title=""> <b> cite=""> <cite> <code> <डेल DateTime = ""> <em> <i> <q cite=""> <strike> <strong>

Subscribe to comments feature has been disabled. टिप्पणी की सुविधा है विकलांग गया है की सदस्यता लें. To receive notification of latest comments posted, subscribe to सदस्यता के लिए नई टिप्पणियों की सूचना प्राप्त पोस्ट किया है, My Digital Life Comments RSS feed मेरे डिजिटल जीवन टिप्पणियाँ आरएसएस फ़ीड or या register to receive रजिस्टर प्राप्त करने के लिए new comments in daily email digest. दैनिक ईमेल में नई टिप्पणियाँ डाइजेस्ट.
Custom Search

New Articles नए लेख

Incoming Search Terms for the Article के लिए खोजें शर्तें आने अनुच्छेद

mysql replace mysql की जगह - -- sql find and replace SQL खोजें और जगह - -- MySQL replace text MySQL पाठ की जगह - -- replace mysql जगह mysql - -- sql find replace SQL जगह मिल - -- MySQL search and replace MySQL खोज और स्थान - -- replace in mysql mysql में जगह - -- sql replace text SQL पाठ की जगह - -- mysql replace example mysql उदाहरण की जगह - -- mysql find and replace mysql खोजें और जगह - -- find replace sql की जगह मिल एसक्यूएल - -- mysql update text mysql अद्यतन पाठ - -- mysql replace string mysql धागे की जगह - -- mysql search and replace string mysql खोज और जगह तार - -- search and replace mysql खोज और स्थान mysql - -- find replace sql query SQL प्रश्न की जगह मिल - -- find replace mysql की जगह मिल mysql - -- find replace in mysql खोज mysql में जगह - -- find and replace mysql खोजें और mysql की जगह - -- mysql string REPLACE mysql धागे REPLACE - -- mysql find mysql मिल - -- update replace mysql mysql अद्यतन की जगह - -- find and replace using sql खोजें और एसक्यूएल प्रयोग की जगह - -- find and replace sql खोजें और SQL की जगह - -- mysql update replace string mysql अद्यतन तार की जगह - -- mysql substitute string mysql विकल्प स्ट्रिंग - -- mysql replace all mysql सब जगह - -- mysql find replace mysql की जगह मिल - -- mysql replace command mysql कमान की जगह - -- mysql select replace mysql चुनें जगह - -- mysql search and replace data in database mysql डेटाबेस में खोज और स्थान डेटा - -- MYSQL REPLACE SYNTAX MYSQL REPLACE वाक्यविन्यास - -- php mysql replace php mysql की जगह - -- replace in mysql query mysql क्वेरी में स्थान - -- replace mysql syntax mysql वाक्यविन्यास की जगह - -- replace word within description sql वर्णन एसक्यूएल भीतर शब्द की जगह - -- replace sql जगह एसक्यूएल - -- replace mysql example mysql उदाहरण की जगह - -- Replace text string sql बदलें पाठ स्ट्रिंग एसक्यूएल - -- replace mysqkl जगह mysqkl - -- search and replace sql खोज और स्थान एसक्यूएल - -- search and replace in mysql खोज और mysql में जगह - -- sql replace text in table SQL तालिका में पाठ की जगह - -- sql update search and replace SQL अद्यतन खोज और स्थान - -- sql search and replace SQL खोज और स्थान - -- sql replace example SQL उदाहरण की जगह - -- sql search and replace query SQL खोज और स्थान प्रश्न - -- sql query search and replace SQL क्वेरी के खोज और स्थान - -- sql find replace SQL जगह मिल - -- sql replace string statement SQL स्ट्रिंग बयान की जगह - --