Troubleshooting SELECT Privileges Issue with Drupal 9 Views Integration
For me and a few other users, with Civi &amp; Drupal in separate databases, this was solved by comment #4 on Views integration error on D9:

Try removing the back ticks ... '`' from the prefix information in the settings.local.php

(or settings.php in my case.)
If it's not working for you with Civi &amp; Drupal in the same database, assuming you've removed the code that you pasted into the settings file, maybe try Jon G's solution at How to get CiviCRM Views to work in Drupal 8 with separate CiviCRM database.