Added support for databases with hyphens in the name. Requires a bracketed DB name.