0

INSERT INTO a2.cat (id, img) SELECT category_id, category_id FROM topshop.category;

我需要在 category_-id 的列 img 中插入加值

INSERT INTO a2.cat (id, 'c'+img+'.jpg') SELECT category_id, category_id FROM topshop.category;
4

1 回答 1

1

这里是:

INSERT INTO a2.cat 
  (id, img) 
SELECT 
  category_id, CONCAT('c',category_id,'.jpg')
FROM topshop.category;
于 2013-05-25T01:00:07.020 回答