M
M
melnikov_m2014-10-20 18:00:50
MySQL
melnikov_m, 2014-10-20 18:00:50

How to change field value in multiple rows with one SQL query?

There is a 'name' field in the '
geo ' table that stores names like this . Urban district - Cherkessk Urban district - Karachaevsky Urban district - Cheboksary Urban district - Alatyr PS : MySQL -5.5.38

Answer the question

In order to leave comments, you need to log in

4 answer(s)
N
Nursultan Moldobaev, 2014-10-20
@melnikov_m

sqlfiddle.com/#!2/a4026/10

R
Rsa97, 2014-10-20
@Rsa97

Why is there a regular? LIKE , SUBSTRING , CONCAT

W
whats, 2014-10-20
@whats

SELECT concat('Городской округ - ', SUBSTRING_INDEX('Алатырский городской округ', 'городской округ', 1))

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question