Moved ordering so db:get-subdb is available