0
votes

Application Insights analytics Queries are designed on Dev environment. Now want to set up for staging. Created 2 resources for App Insights, one for dev and other for Staging. Is there any way i can directly export Dev queries to staging in analytics.

Tried with shared queries in Query Explorer.

How to setup Dev, Staging and Production environments for App Insights Dashboard?

1
Just to clarify, in staging env, you want to query from dev?Ivan Yang
want to set up 2 dashboards one for Dev and one for Staging. For dev dashboard, charts are pin from Dev App Insights. For staging i want to use same queries as Dev.. and then pin those to Staging dashboard. Is there any way where i can get all Dev queries available in staging?smp

1 Answers

0
votes

Please correct me if I misunderstand you.

In your case, you can use app() expression for across multiple applications query, then generate charts -> pin to dashboard.

A simple example as below, I have 2 application insights resources named mvc111 and ivanAppInsights . And in mvc111, I want to query from ivanAppInsights.

In the application named mvc111 -> analytics:

app("ivanAppInsights").requests
| where timestamp > ago(20d)
| render barchart

Then select pin button to add the chart to dashboard:

enter image description here

At last, nav to the dashboard(if no data in the dashboard, please pick a time range in the dashboard):

enter image description here