Minor corrections to allow the usage of a custom descriptor with SQL Server

Three minor changes that allow the usage of a custom Descriptor when connecting to a SQL Server which at least to where I could investigate wasn't working properly. But feel free to curse me if I'm mistaken ;).