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

Line chart series input doesnt work | Clickhouse #13312

mikekytyzov opened this issue Feb 24, 2021 · 2 comments

Line chart series input doesnt work | Clickhouse #13312

mikekytyzov opened this issue Feb 24, 2021 · 2 comments


Copy link

@mikekytyzov mikekytyzov commented Feb 24, 2021

A clear and concise description of what the bug is.

I have a metric called Total users. I want to make a line chart with this metric by day, but display only 5 top results per day.

So, i select series input to 5, but it doesnt work, all results still displayed. Screen is attached

Expected results

Series is applied by each time granula.

Actual results

Series input doesnt make any affect


Screenshot 2021-02-24 at 11 01 30

How to reproduce the bug

  1. Try create line chart with a lot of data
  2. Select series to 5
  3. See that series doesnt make any affect


(please complete the following information):

  • superset version: 0.34.1
  • python version: 3.6.12

may be related to #11426

Adding sorting option doesnt not have affect. Also area chart works with the same bug.

@mikekytyzov mikekytyzov added the #bug label Feb 24, 2021
@junlincc junlincc added the v0.34 label Feb 24, 2021
Copy link

@anilvpatel21 anilvpatel21 commented Mar 8, 2021

@mikekytyzov In the above case, Sub Query is not generated when applying series limit in clickhouse db. It might be because Window function is not supported in the clickhouse.(Guess)

As a work around, you may apply actual query & create datasource with Limit By functionality. And then apply dummy query on the top of the datasource using visualisation (viz. of line chart).
Example: SELECT colnames FROM tbl (clickhouse db) WHERE time_received >= toDateTime('{{ from_dttm }}') AND time_received < toDateTime('{{ to_dttm }}') LIMIT 5 BY time_received -- Here time_recieved is the time column. Using this as a datasource, you will achieve it.

@junlincc Its not working in v1.0.1 also.

Copy link

@mikekytyzov mikekytyzov commented Mar 8, 2021

@anilvpatel21 okay, i see. thanks for response.

btw ch already have window functions, but as experimental feature

will you add a support of it ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
3 participants