[api] speeding up SQL request handling a bit more
[api] avoid a crash on SLE 11 installation