Can you change this to match the style to check for query execution we commonly use in the DAOs.

``` C++
if (!query.exec()) {
    LOG_FAILED_QUERY(query) << "coud not select track locations";
    return QSet<int>();
}

while (query.next()) {
    qDebug() << query.value(0).toString();
}
```