mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
Alerting: Fix boolean comparison on PostgreSQL (#54730)
This commit is contained in:
parent
ac93cf1db2
commit
77e53f9986
@ -460,7 +460,7 @@ func (st DBstore) GetAlertRulesForScheduling(ctx context.Context, query *ngmodel
|
||||
}
|
||||
var rules []*ngmodels.AlertRule
|
||||
return st.SQLStore.WithDbSession(ctx, func(sess *sqlstore.DBSession) error {
|
||||
foldersSql := "SELECT D.uid, D.title FROM dashboard AS D WHERE is_folder = 1 AND EXISTS (SELECT 1 FROM alert_rule AS A WHERE D.uid = A.namespace_uid)"
|
||||
foldersSql := "SELECT D.uid, D.title FROM dashboard AS D WHERE is_folder IS TRUE AND EXISTS (SELECT 1 FROM alert_rule AS A WHERE D.uid = A.namespace_uid)"
|
||||
alertRulesSql := "SELECT * FROM alert_rule"
|
||||
filter, args := st.getFilterByOrgsString()
|
||||
if filter != "" {
|
||||
|
Loading…
Reference in New Issue
Block a user