if db dir is file