Looks like an issue with quotation marks that have been inserted in odd places in the query - certainly it’s a syntax error and not any issue with access.
Is this a custom SQL query alert rule, or one you built in the UI? If it’s the latter can you share a screenshot or (probably better) copy and paste the summary from the Rule column in the Alert Rules table in the GUI.
Also I’d watch Alerts Blank - macros.device_down Broken - SQL Error syntax error or access violation: 1064 which seems to be the same issue actually…