Best method for obtaining the 'sid' of a task?