Hi, here's the Diagnostic Info:
{
"browser-info": {
"language": "es-419",
"platform": "Win32",
"userAgent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/126.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.23+9",
"java.vendor": "Eclipse Adoptium",
"java.vendor.url": "https://adoptium.net/",
"java.version": "11.0.23",
"java.vm.name": "OpenJDK 64-Bit Server VM",
"java.vm.version": "11.0.23+9",
"os.name": "Linux",
"os.version": "5.10.219-208.866.amzn2.x86_64",
"user.language": "en",
"user.timezone": "GMT"
},
"metabase-info": {
"databases": [
"postgres",
"mysql",
"bigquery-cloud-sdk",
"h2"
],
"hosting-env": "unknown",
"application-database": "postgres",
"application-database-details": {
"database": {
"name": "PostgreSQL",
"version": "14.10"
},
"jdbc-driver": {
"name": "PostgreSQL JDBC Driver",
"version": "42.7.2"
}
},
"run-mode": "prod",
"version": {
"date": "2024-06-25",
"tag": "v1.49.18",
"hash": "fd3765d"
},
"settings": {
"report-timezone": null
}
}
}
As per the logs it shows:
{
:status :failed,
:class clojure.lang.ExceptionInfo,
:error "Error reducing result rows: Subquery returns more than 1 row",
:stacktrace
.... (long stacktrace)
:card_id 334,
:context :question,
:error "Subquery returns more than 1 row",
:row_count 0,
:running_time 0,
:data {:rows [], :cols []}
}
The query produces the subquery +1 error as expected, however the SQL query file itself is like frozen and doesn't allow me to update the code to fix the +1 results error.
On the error, since you’ve identified the dirty record, do you get different errors if you try to query just that record?
Using the same SQL query file in Metabase, I can't update the code to try only with this record. I have to create a different SQL query file. The only error it produces is a subquery +1 results error.
Do you get similar errors with the same query in other editors like DBeaver and Datagrip?
Yes, the error arises from a data anomally that shouldn't have happend, but it did anyways. Problem is I want to modify the query to simply add a MAX() in the subquery to get any of the multiple records as it doesn't really matter what the record is, only that it exists
As it's shown in the video I shared, any modification I try on the SQL query file is discarded when I run the query and the Save button doesn't show up. The file seems to be locked somehow.