queryHistory , queryToPromise