Hi,
I have simple problem and tried many solution but not successful, I will explain from starting.
I have a table from which I took total count of raws as count_1 , another count_2 will be after applying some filter on the same table. Now I have to divide the both counts to get the percentage. This is view I need.
Solution I tried.
-
As we can't not divide in same question , I will create two different questions and then join them and then using the formula "Sum([Question 135 → Count]) / Sum([Count]) * 100" . Here the problem is after clicking on numbers i couldn't see all records details.
-
I have written native query in metabase by selecting all records and join them using
select x.number / y.number
from
(
query 1
) x
join
(
query 2
) y on 1=1
here again , it says because of question written in sql, you can't drill through. I turned it into a model tried to drill through , now only numbers are showing no details still.
- Again joining two queries, but with all records. And tried to calculate percentage after convert it into model.
select *
from
(
query 1
) x
join
(
query 2
) y on 1=1
But still not able to divide two counts here so that I can see all records.
PLease help and suggested a genuine solution.
FYI- I am using the latest version , attaching Diagnostic Info
{
"browser-info": {
"language": "en-GB",
"platform": "MacIntel",
"userAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/117.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.20.1+1",
"java.vendor": "Eclipse Adoptium",
"java.vendor.url": "https://adoptium.net/",
"java.version": "11.0.20.1",
"java.vm.name": "OpenJDK 64-Bit Server VM",
"java.vm.version": "11.0.20.1+1",
"os.name": "Linux",
"os.version": "5.4.0-1029-aws",
"user.language": "en",
"user.timezone": "GMT"
},
"metabase-info": {
"databases": [
"postgres",
"mongo",
"csv",
"h2"
],
"hosting-env": "unknown",
"application-database": "postgres",
"application-database-details": {
"database": {
"name": "PostgreSQL",
"version": "15.2 (Debian 15.2-1.pgdg110+1)"
},
"jdbc-driver": {
"name": "PostgreSQL JDBC Driver",
"version": "42.5.4"
}
},
"run-mode": "prod",
"version": {
"date": "2023-09-18",
"tag": "v0.47.2",
"branch": "release-x.47.x",
"hash": "536c24c"
},
"settings": {
"report-timezone": null
}
}
}
Thanks.