Using SUBSTR in query breaks the question

Hello,

Whenever I use SUBSTR for an SQL query, it breaks the question by showing the following message "Sorry, you don't have permission to see that".
Here's the screenshot

There is also nothing in the logs to indicate what is going wrong.

The Diagnostic Info;

{
"browser-info": {
"language": "en-US",
"platform": "Win32",
"userAgent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/106.0.0.0 Safari/537.36",
"vendor": "Google Inc."
},
"system-info": {
"file.encoding": "UTF-8",
"java.runtime.name": "OpenJDK Runtime Environment",
"java.runtime.version": "11.0.16.1+1",
"java.vendor": "Eclipse Adoptium",
"java.vendor.url": "https://adoptium.net/",
"java.version": "11.0.16.1",
"java.vm.name": "OpenJDK 64-Bit Server VM",
"java.vm.version": "11.0.16.1+1",
"os.name": "Linux",
"os.version": "3.10.0-1160.36.2.el7.x86_64",
"user.language": "en",
"user.timezone": "GMT"
},
"metabase-info": {
"databases": [
"h2",
"oracle"
],
"hosting-env": "unknown",
"application-database": "mysql",
"application-database-details": {
"database": {
"name": "MySQL",
"version": "8.0.19"
},
"jdbc-driver": {
"name": "MariaDB Connector/J",
"version": "2.7.6"
}
},
"run-mode": "prod",
"version": {
"date": "2022-10-17",
"tag": "v0.44.5",
"branch": "release-x.44.x",
"hash": "29fab4d"
},
"settings": {
"report-timezone": "Africa/Lagos"
}
}
}

Hi @oaajibade
It's caused by a WAF blocking the request: https://www.metabase.com/docs/latest/troubleshooting-guide/proxies

Thanks for this.

Is there any walkaround to address this problem?

@oaajibade Yes, fix your WAF or disable it.

Thanks @flamber.
I guess that was the issue. Quite surprised why Cloudflare has this aggressive behavior.