Skip to content

type/FK -> column and type/FK -> type/Name field values remapping doesn't work in QB filter widgets when Search box is used #45063

@ranquild

Description

@ranquild

Describe the bug

Automatic PK field values remapping to a field with "Entity Name" semantic type doesn't work in query builder widgets with Search box. The same with FK -> Use foreign key -> Column remapping.

To Reproduce

type/FK -> type/Name:

  1. Admin -> Table Metadata -> People.
  2. Make sure that People.Name has Entity Name semantic type.
  3. Make sure that People.ID has Search box in Filtering on this field section (has_field_values property).
  4. New -> Question -> Tables -> People
  5. Filter -> ID
  6. Start typing a person name. Nothing happens - there is no autocomplete.
  7. Enter some valid person ID and add this filter.
  8. Open the filter again. See that the value is not remapped either.

type/FK -> column:

  1. Admin -> Table Metadata -> Orders.
  2. Open PRODUCT_ID -> Remapping -> Use foreign key -> Select Product.Title.
  3. Make sure there is Search box enabled as well.
  4. New -> Question -> Tables -> Orders
  5. Filter -> Product ID
  6. Start typing a product title. Nothing happens - there is no autocomplete.
  7. Enter some valid product ID and add this filter.
  8. Open the filter again. See that the value is not remapped either.

Expected behavior

Both cases work with List of values. They should work with Search box.
Screenshot 2024-07-02 at 15 19 51
Screenshot 2024-07-02 at 15 21 13

Logs

No response

Information about your Metabase installation

- v50

Severity

P1

Additional context

No response

Metadata

Metadata

Labels

.Team/QueryingPriority:P1Security holes w/o exploit, crashing, setup/upgrade, login, broken common features, correctnessQuerying/GUIQuery builder catch-all, including simple modeQuerying/MBQLType:BugProduct defects

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions