-
Notifications
You must be signed in to change notification settings - Fork 5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Drill-through on a timestamp column binned as XofY fails unless sematic type is defined #23851
Labels
Administration/Metadata & Sync
.Backend
Priority:P2
Average run of the mill bug
Querying/GUI
Query builder catch-all, including simple mode
Type:Bug
Product defects
.Wanted: MLv2
Issues that will be fixed (or easier to fix, or possible to fix) when we have MLv2
Projects
Comments
Very related to #18011 |
@paoliniluis can you confirm this has been fixed, I can not reproduce |
Reproducible in 0.48.0. |
kamilmielnik
added a commit
that referenced
this issue
Mar 4, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
Administration/Metadata & Sync
.Backend
Priority:P2
Average run of the mill bug
Querying/GUI
Query builder catch-all, including simple mode
Type:Bug
Product defects
.Wanted: MLv2
Issues that will be fixed (or easier to fix, or possible to fix) when we have MLv2
Describe the bug
When a timestamp field hasn't been explicitly casted as a timestamp, Metabase will build invalid queries.
Logs
DB query: SELECT "public"."orders"."id" AS "id", "public"."orders"."user_id" AS "user_id", "public"."orders"."product_id" AS "product_id", "public"."orders"."subtotal" AS "subtotal", "public"."orders"."tax" AS "tax", "public"."orders"."total" AS "total", "public"."orders"."discount" AS "discount", "public"."orders"."created_at" AS "created_at", "public"."orders"."quantity" AS "quantity" FROM "public"."orders" WHERE "public"."orders"."created_at" = 6 LIMIT 2000
ERROR: operator does not exist: timestamp without time zone = integer at character 557
Metabase log
To Reproduce
Also, see the filter on the top ("[Unknown]")
Interesting fact: Metabase knows that it's a timestamp field (go to query builder and click on the filter)
![image](https://user-images.githubusercontent.com/1711649/178397552-cea0d889-e9d7-4311-8381-66be3d4db8e0.png)
Expected behavior
Build the correct query for the drill down to happen correctly
Screenshots
![query_type_casts](https://user-images.githubusercontent.com/1711649/178397770-aa3807ae-94ab-4de5-8fca-cc3ce70801b2.gif)
Information about your Metabase Installation:
Severity
P2'ish
Additional context
Is this frontend?
The text was updated successfully, but these errors were encountered: