You could pass the yarn queue in the bash script task to make sure the hive query that you execute runs in that particular yarn queue.
Place the .sql file which has the query on the edge node and put the below command in the bash node of a workflow. Here the name of the Yarn queue is TERA.
hive -f <path_to_the_sql_file>/start_batch.sql -hiveconf tez.queue.name=TERA
Note: You can pass any other hive configuration variables using the -hiveconf argument.
Applicable Infoworks Versions