Skip to content
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

[Visualize] filter doesn't work filter on scripted fields of Array Type. #148942

Closed
dawn023349 opened this issue Jan 15, 2023 · 7 comments
Closed
Labels
bug Fixes for quality problems that affect the customer experience Feature:Filters impact:low Addressing this issue will have a low level of impact on the quality/strength of our product. Team:Visualizations Visualization editors, elastic-charts and infrastructure

Comments

@dawn023349
Copy link
Contributor

Kibana version
: 8.5.3

summary
: Currently, "Visualize Library" filter query doesn't work on scripted fields of Array Type.
This happens in both 'number type' and 'string type'.

Steps to reproduce:

▪️ devTools

# 01. Create index
PUT test_index
{
  "mappings":{
    "properties":{
      "x_arr":{
        "type":"keyword"
      },
      "y_arr":{
        "type":"integer"
      }
    }
  }
}

# 02. Put Arr field doc
PUT test_index/_doc/1
{
  "x_arr":["a","b","c","d"],
  "y_arr":[1,2,3,4]
}
PUT test_index/_doc/2
{
  "x_arr":["e","f","g","h"],
  "y_arr":[5,6,7,8]
}

▪️ create data view and add scripted fields
image

▪️ ES field filter (click chart - "b")
image

▪️ ❗scripted field filter (click chart - "b")
image
image

@dawn023349 dawn023349 added the bug Fixes for quality problems that affect the customer experience label Jan 15, 2023
@botelastic botelastic bot added the needs-team Issues missing a team label label Jan 15, 2023
dawn023349 added a commit to dawn023349/kibana that referenced this issue Jan 15, 2023
- ISSUE
[Dashboard] Visualize Library doesn't work filter on scripted fields of Array Type. elastic#148942
@ThomThomson ThomThomson changed the title [Dashboard] Visualize Library doesn't work filter on scripted fields of Array Type. [Visualize] filter doesn't work filter on scripted fields of Array Type. Jan 16, 2023
@ThomThomson ThomThomson added Feature:Filters Team:Visualizations Visualization editors, elastic-charts and infrastructure and removed needs-team Issues missing a team label labels Jan 16, 2023
@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-visualizations @elastic/kibana-visualizations-external (Team:Visualizations)

@stratoula stratoula added the impact:low Addressing this issue will have a low level of impact on the quality/strength of our product. label Jan 17, 2023
@stratoula
Copy link
Contributor

This is a bug with scripted field but as we consider them deprecated I created one runtime field instead
image

With the runtime field, filters work fine so I am closing this
image

@dawn023349
Copy link
Contributor Author

@stratoula!
Thank you for telling me the other way.
But,
Shouldn't it be fixed because it's still available?

@stratoula
Copy link
Contributor

@dawn023349 sorry if this causes any inconvenience. If the bug was in runtime fields we would have fixed that but this bug seems to exist for some minors and is on a feature that is going to be removed. So we prefer to give priority to non-deprecated features.

@dawn023349
Copy link
Contributor Author

@stratoula , thanks for the details.
I understood what you said.
Then, can't review my pull request(#148943) for the same reason too?

@stratoula
Copy link
Contributor

stratoula commented Jan 18, 2023

I am sorry, it seems we missed your contribution! (I am not part of the app-services team). If this solves the problem and doesn't create any regression, we will happily review it. I will ping the team :)

@dawn023349
Copy link
Contributor Author

Oh!
Thank you very much for your quick and continuous reply!

I wish you a Happy New Year!😄
hope to see you again sometime.
Thank You.

lukasolson added a commit that referenced this issue Jan 24, 2023
…48943)

- ISSUE [Dashboard] Visualize Library doesn't work filter on scripted
fields of Array Type. #148942

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: Lukas Olson <lukas@elastic.co>
jloleysens added a commit to jloleysens/kibana that referenced this issue Jan 24, 2023
* main: (54 commits)
  [APM] Allow calling `createInternalESClient` without `context` (elastic#149320)
  [Synthetics] Errors list active state (elastic#149387)
  [FTRs] Execution Context: fix no data flakiness (elastic#149406)
  [Cloud Posture] - Deprecate csp rule remove migration object (elastic#148530)
  Bump elasticsearch-js to 8.6.0-canary.3 (elastic#148521)
  [Fleet] Use optimistic locking when updating `installed_es` on input package policy creation (elastic#148883)
  [ML] Remove job_type from job definitions in modules (elastic#149247)
  [ML] Consolidate `query_utils` into package `@kbn/ml-query-utils` (elastic#149224)
  [Synthetics] Better formatting for waterfall timeline tooltips (elastic#149142)
  [Cloud Posture] CIS AWS support - changes to findings tables (elastic#148945)
  [Lens] Enable previous time shift when using a date histogram (elastic#149126)
  [Synthetics] Object types panel and thresholds (elastic#149099)
  [Fleet] added back batch exec for update tags (elastic#148618)
  148790 - Fix scroll style for setup guide flyout (elastic#149242)
  Fix a11y issue with dev tool tabs (elastic#149349)
  [APM] Fix mobile indices (elastic#149230)
  [Dashboard] Fix Phrase_filter query for scripted fields (elastic#148942) (elastic#148943)
  renderCustomActionsRow with named params instead of args (elastic#149304)
  [ML] Adding ML execution context to es requests (elastic#148746)
  [Custom Branding] Replace EuiLoadingElastic with EuiLoadingSpinner (elastic#149261)
  ...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Fixes for quality problems that affect the customer experience Feature:Filters impact:low Addressing this issue will have a low level of impact on the quality/strength of our product. Team:Visualizations Visualization editors, elastic-charts and infrastructure
Projects
None yet
Development

No branches or pull requests

4 participants