Group by distinct values of numeric field

When creating a query, summarizing by a numeric field always creates a binned histogram and doesn't appear to allow aggregating by distinct values of the field. This is especially problematic for numeric fields which represent enumerated values as the aggregations do not make any sense.

I tried converting the question to SQL and manually aggregating by the field, but I then can't create a pivot table as Metabase doesn't think the query is valid for a pivot table visualization.


select count("sales"."id") as "count", "sales"."status" as "status", "products"."name" as "name"
from "sales" left join "products" on "products"."sale_id" = "sales"."id"
group by "products"."name", "sales"."status"
order by count("sales"."id") limit 10

Hi @LeoAdamek
I don't think I understand. Can you show a screenshot of your problem with the GUI question?
And post "Diagnostic Info" from Admin > Troubleshooting.

Here's the diagnostic info:

This is the area of issue, there's no way to simply group by distinct values of this numeric field, only group into buckets.

  "browser-info": {
    "language": "en-US",
    "platform": "Win32",
    "userAgent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/ Safari/537.36",
    "vendor": "Google Inc."
  "system-info": {
    "file.encoding": "UTF-8",
    "": "OpenJDK Runtime Environment",
    "java.runtime.version": "1.8.0_322-heroku-b06",
    "java.vendor": "Oracle Corporation",
    "java.vendor.url": "",
    "java.version": "1.8.0_322-heroku",
    "": "OpenJDK 64-Bit Server VM",
    "java.vm.version": "25.322-b06",
    "": "Linux",
    "os.version": "4.4.0-1104-aws",
    "user.language": "en",
    "user.timezone": "Etc/UTC"
  "metabase-info": {
    "databases": [
    "hosting-env": "heroku",
    "application-database": "postgres",
    "application-database-details": {
      "database": {
        "name": "PostgreSQL",
        "version": "14.4 (Ubuntu 14.4-1.pgdg20.04+1)"
      "jdbc-driver": {
        "name": "PostgreSQL JDBC Driver",
        "version": "42.2.23"
    "run-mode": "prod",
    "version": {
      "tag": "v0.42.4",
      "date": "2022-04-07",
      "branch": "release-x.42.x",
      "hash": "7c3ce2d"
    "settings": {
      "report-timezone": "Europe/London"

@LeoAdamek Click the "100 bins" to select Unbinned. Latest release is 0.44.1