Can you get the number of hits and the time taken for a query with hive?

I've been looking around for this and other than doing a select count there doesn't seem to be a quick way to get the number of hits when creating a table with a query from hive. Maybe I miss something because when I do a show tblproperties on a table created with the elasticsearch handler it doesn't show the row count.

Also, is there a way to order the results by relevance when creating the hive table with a query?

You have to compute the statistics.

analyze table TABLE_NAME compute statistics;