# 2 ESQL requests in one request

**URL:** <https://discuss.elastic.co/t/2-esql-requests-in-one-request/357453>\
**Category:** Elasticsearch\
**Created:** [April 15, 2024, 6:52pm UTC](https://discuss.elastic.co/t/2-esql-requests-in-one-request/357453 "2024-04-15T18:52:05Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Aleksei](https://avatars.discourse-cdn.com/v4/letter/a/7c8e57/32.png) [@Aleksei](https://discuss.elastic.co/u/Aleksei)\
**Post date:** [April 15, 2024, 6:52pm UTC](https://discuss.elastic.co/t/2-esql-requests-in-one-request/357453/1 "2024-04-15T18:52:05Z")

</div>

Hi all.  
Has anyone already dived into ES|QL?  
I'm interested in how to build two queries in one general query.  
To then calculate the % ratio based on the results of these queries.

For example  
A/(B+A)\*100  
A - is the first request.  
B - second request.

Then this can be calculated through division [ES|QL functions and operators | Elasticsearch Guide [8.13] | Elastic](https://www.elastic.co/guide/en/elasticsearch/reference/current/esql-functions-operators.html#_divide) and other mathematical operations.

As I understand it, you can’t do this through eval, it seems like you can’t assign an entire request to a variable through eval 🤔
