fix CreateDatabaseDirectory

This fixes possible filesystem errors when IIS and SQL Server are not on the same server.