Complex queries

is there a way to write a query that will check if the value of a field is within an array

my problem is the following, I have a field that represents domains, I would like to filter all the data the came in from a list of domains but it is about 40-50 domains I tried building a long OR statement but it breaks and doesn't work any recommendations?

another question, is there a way to create a metric that basically is the result of other 2 metrics with a formula Metric A / Metric B

For example I want to be able to show conversion rates, so I want to aggregate all pages views and then aggregate all clicks and divide accordingly on a per page basis - is this possible?

A query filter with a number of OR statements is the only way I can think to do that. Does it work with a smaller list of domains? Can you perhaps share the query you tried? And also, how does it break?

That should be possible in Elasticsearch using Pipeline Aggregations, but unfortunately Kibana doesn't support pipelines yet.