Hi Daniel, this is not working because as soon as I use an external join the resulting SQL is setting the default value of the folderID in the source table as 0. If there was a way to use the 'default' (attribute of <element> element) properly, then, it would have been solved.