# 2. Pull Queries

![](/files/-MDZMZfGm512KcdwU8al)

![](/files/-MDZMWUS3CcvqS3rDQBD)

![](/files/-MDZMpaBvSefq5yUJqJJ)

Now create a aggregate table first so that we can apply PULL query :

![](/files/-MDZN8scv8U5UzfcW4mL)

Now ran the PULL query. (This query is always stops not running continuosly . Also there is no need to add EMIT CHANGES just as in case of PUSH queries.

![](/files/-MDZNIXtS_DO6ijU19cb)

Add one more in the STREAM.

![](/files/-MDZNp751ERArC92VftX)

Pull query gives the immediate results .


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://architectures.gitbook.io/project/apahce-kafka/ksql-on-ksqldb-for-stream-processing/ksql-intermediate/2.-pull-queries.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
