Add log queries