You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@superset.apache.org by GitBox <gi...@apache.org> on 2022/03/31 20:02:15 UTC

[GitHub] [superset] prosdev0107 opened a new pull request #19475: fix(chart & quarter): make to set quarter as [2, 5, 8, 11]

prosdev0107 opened a new pull request #19475:
URL: https://github.com/apache/superset/pull/19475


   ### SUMMARY
   Quarter Time Grain Alignment
   
   ### BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF
   BEFORE:
   ![image](https://user-images.githubusercontent.com/47900232/161139637-9ead62f1-49e8-457b-9777-cc9a0c1d7e21.png)
   
   AFTER:
   ![image](https://user-images.githubusercontent.com/47900232/161139370-6e6c53f5-90d0-4ad4-b840-0390c937bf5a.png)
   
   
   ### TESTING INSTRUCTIONS
   **How to reproduce bugs**
   
   1. Chart a time series V2 chart using netflix demo data
   2. Time: Date added grain as day
   3. Metric: Count
   4. group-by: Type
   5. Time range: 01/01/2019 - 01/01/2020
   6. Run graph
   7. Toggle to “Quarter” time grain
   
   ### ADDITIONAL INFORMATION
   <!--- Check any relevant boxes with "x" -->
   <!--- HINT: Include "Fixes #nnn" if you are fixing an existing issue -->
   - [ ] Has associated issue:
   - [ ] Required feature flags:
   - [ ] Changes UI
   - [ ] Includes DB Migration (follow approval process in [SIP-59](https://github.com/apache/superset/issues/13351))
     - [ ] Migration is atomic, supports rollback & is backwards-compatible
     - [ ] Confirm DB migration upgrade and downgrade tested
     - [ ] Runtime estimates and downtime expectations provided
   - [ ] Introduces new feature or API
   - [ ] Removes existing feature or API
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [superset] zhaoyongjie commented on pull request #19475: fix(chart & quarter): make to set quarter as [2, 5, 8, 11]

Posted by GitBox <gi...@apache.org>.
zhaoyongjie commented on pull request #19475:
URL: https://github.com/apache/superset/pull/19475#issuecomment-1086445973


   @prosdev0107, the **grain** means how granularity is aggregated by the query.  For instance, we have a dataset that contains everyday data for a year. You will get an aggregated dataset after it applies **grain**.
   
   If you want to change aggregated **grain**, you should change the grain function in the backend instead of alignment data in the frontend.
   
   ### aggregated by day
   <img width="1182" alt="image" src="https://user-images.githubusercontent.com/2016594/161358152-26aa0af3-358b-4280-931a-1a2bca3fe2e7.png">
   
   ### aggregated by quarter
   <img width="1417" alt="image" src="https://user-images.githubusercontent.com/2016594/161357537-bb4ecc78-6c54-4f50-87c0-2798871ec8c2.png">
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [superset] prosdev0107 commented on pull request #19475: fix(chart & quarter): make to set quarter as [2, 5, 8, 11]

Posted by GitBox <gi...@apache.org>.
prosdev0107 commented on pull request #19475:
URL: https://github.com/apache/superset/pull/19475#issuecomment-1086088511


   @zhaoyongjie .
   This issue is happened when The time grain filter value has quarter in chart.
   The quarter is setting [1, 3, 7, 10](Jan, Mar, July, Oct) and so this chart seems to be wrong.
   So I tried to make the quarter as [2, 5, 8, 11] and then I did it on frontend side.
   
   I think that the best solution is to update this part on backend side but this is using superset/api/v1/chart/data for getting chart data.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org