W
W
WebforSelf2020-07-09 21:47:58
MySQL
WebforSelf, 2020-07-09 21:47:58

How to assign the value of one field to another + numbers?

We have 2 fields

id and sku

in id there is a unique value from 1 ....
and in sku it is empty, the task is to assign all sku = id , but the difficulty is that you need to add the number 700 to sku,
for example
id sku
1 7001
245 700245

Answer the question

In order to leave comments, you need to log in

1 answer(s)
W
WebforSelf, 2020-07-09
@WebforSelf

UPDATE `table` set `sku` = concat("700", id);

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question