Improved reordering mechanics of ByPropertyIdArray

Change-Id: I3d4ff8648dad27ce3754a3d302af43797a5a202c
(cherry picked from commit 997b499b166b41c21c2ef110112c8ddf3b4dd0c7)