Hello @ricardoatsouza,
Unfortunately, there is no way to perform cross-measurement math or grouping with influxql. All data must be under a single measurement to query it together. This issue has been raised. With Flux you will be able to do this.
Best,
Anais