This eliminates several select statements issued while walking up the parent hierarchy
The V1.2.1 - V1.3 script has been updated and tested, but if you want to keep an existing 1.3, then:
SET FOREIGN_KEY_CHECKS = 0;
ALTER TABLE node ADD `acl_id` bigint(20) default NULL;
UPDATE node node SET node.acl_id = (SELECT acl.id FROM access_control_list acl WHERE acl.node_id = node.id);
SET FOREIGN_KEY_CHECKS = 1;
git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@2910 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261