活动

二月 4
Minhchau Dang 对 LPS-62914 进行了评论。
下午6:09 We really shouldn't be updating the Group_ table one entry at a time. Instead, we should come up with some way of doing the updates in bulk. One approach would be to build the tree path for all root sites, then update everything on the next level by looking at the immediate children of those nodes that we've set a tree path on by using temporary tables. That way, rather than updating each group one at a time, we will perform a number of updates equal to the deepest part of the tree. All we would need is to find out how to concatenate strings across databases. The pseudo-code for that would look something like this: {code} update Group_ set treePath = concat('/', groupId) where parentGroupId = 0 count_value = select count(*) from Group_ where treePath is null while count_value > 0: create temporary table GroupsToUpdate ( select ChildGroup.groupId as groupId, concat(ParentGroup.treePath, '/', ChildGroup.groupId) as treePath from Group_ ChildGroup inner join Group_ ParentGroup on ChildGroup.parentGroupId = ParentGroup.groupId where ChildGroup.treePath is null and ParentGroup.treePath is not null ) add index to groupId column for GroupsToUpdate update Group_ set treePath = ( select treePath from GroupsToUpdate where Group_.groupId = GroupsToUpdate.groupId ) where exists ( select 1 from GroupsToUpdate where Group_.groupId = GroupsToUpdate.groupId ) drop table GroupsToUpdate count_value = select count(*) from Group_ where treePath is null {code}
一月 27
Minhchau Dang 更新了 LPS-62552。
上午11:21
一月 25
Minhchau Dang 更新了 LPS-49899。
下午1:33
Minhchau Dang 更新了 LPS-48386。
下午1:32
Minhchau Dang 更新了 LPS-49899。
下午1:32
一月 22
Minhchau Dang 更新了 LPS-60388。
Minhchau Dang 更新了 LPS-60369。
十二月 28
Minhchau Dang 更新了 LPS-60383。
Minhchau Dang 更新了 LPS-60373。
Minhchau Dang 更新了 LPS-60377。
订阅 Minhchau Dang 的活动。 (打开新窗口)