mysql一个表内字段的关联
mysql中 下边这句话怎么改能成功呢
update category set country=(
select xx.country from (
select * from category where parentid=left(parentid,8) and country=''
)xx
);
[Err] 1242 - Subquery returns more than 1 row
我知道啥意思 就不会修改
这是在一个表内的相同字段关联,因为有的country不是空的 我要把为空的country通过parentid关联起来 然后把country更新。