dosubot[bot] commented on issue #29237: URL: https://github.com/apache/superset/issues/29237#issuecomment-2165569114
<!-- Greeting --> Hi @vasu-ram! I'm here to help you with any bugs, questions, or contributions you might have for the repository. Let's tackle this together! <!-- Answer --> To fix the issue where the TimeSeries Chart in Superset is displaying the year instead of the month for January, despite setting the Timegrain to "month", you need to ensure that the correct D3 time format is being used. You can set the time format to display the month and year by using one of the D3 time format options. For example, you can use `'%Y-%m'` to display the year and month. Here is how you can set it: ```ts export const D3_TIME_FORMAT_OPTIONS: [string, string][] = [ [SMART_DATE_ID, t('Adaptive formatting')], ['%d/%m/%Y', '%d/%m/%Y | 14/01/2019'], ['%m/%d/%Y', '%m/%d/%Y | 01/14/2019'], ['%Y-%m-%d', '%Y-%m-%d | 2019-01-14'], ['%Y-%m-%d %H:%M:%S', '%Y-%m-%d %H:%M:%S | 2019-01-14 01:32:10'], ['%d-%m-%Y %H:%M:%S', '%d-%m-%Y %H:%M:%S | 14-01-2019 01:32:10'], ['%H:%M:%S', '%H:%M:%S | 01:32:10'], ['%Y-%m', '%Y-%m | 2019-01'], // Add this line to include the year-month format ]; ``` Make sure to select the `'%Y-%m'` format in your chart settings to display the month and year correctly <sup>[[1]](https://github.com/apache/superset/blob/master/superset-frontend/packages/superset-ui-chart-controls/src/utils/D3Formatting.ts)</sup>. <!-- Dosu Comment Footer --> *To continue talking to [Dosu](https://dosu.dev), mention @dosu.* -- 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-unsubscr...@superset.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: notifications-unsubscr...@superset.apache.org For additional commands, e-mail: notifications-h...@superset.apache.org