Base query with callback; query fact with variable