always be verbose when logging db error

When a db query fails the log should always allow us to debug the problem. Not only when the debug flag is set. This PR will log a more useful error message in this case.

@kabum @karlitschek @bartv2 @icewind1991 @DeepDiver1975 

Will have a look if stable6 and master are also shy about the error details.