adding SetConnMaxLifetime configuration (https://golang.org/pkg/database/sql/#DB.SetConnMaxLifetime) to enable refresh of stale connections.
add escape (quote identifiers) for the dynamic sql so tables (collections) with special characters will work.