diff --git a/public/app/features/templating/editor_ctrl.ts b/public/app/features/templating/editor_ctrl.ts index aef5f5ee502..1af5d45be7a 100644 --- a/public/app/features/templating/editor_ctrl.ts +++ b/public/app/features/templating/editor_ctrl.ts @@ -180,6 +180,7 @@ export class VariableEditorCtrl { $scope.datasourceChanged = async () => { datasourceSrv.get($scope.current.datasource).then(ds => { + $scope.current.query = ''; $scope.currentDatasource = ds; }); };