17,377
社区成员
发帖
与我相关
我的任务
分享
update fk_resource
set grade_path=(select a.grade_path from fk_resource a where a.id=fk_resource.father_id) || '/' || cast(id as varchar2(10))
where father_id<>-1
update fk_resource
set grade_path=(select a.grade_path || '/' || cast(a.id as varchar2(10)) from fk_resource a where a.id=fk_resource.father_id)
where father_id<>-1
update fk_resource
set grade_path=(
select a.grade_path||'/'|| cast(id as varchar2(10)) from fk_resource a where a.id=fk_resource.father_id
) where father_id<>-1;