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

Allow user specified granularity in relative time ranges #46

Merged
1 commit merged into from Sep 23, 2014
Merged

Allow user specified granularity in relative time ranges #46

1 commit merged into from Sep 23, 2014

Conversation

ghost
Copy link

@ghost ghost commented Sep 23, 2014

No description provided.

calendar = DateUtils.truncate(calendar, Calendar.MONTH);
} else if ("week".equals(unit)) {
calendar.set(Calendar.DAY_OF_WEEK, Calendar.SUNDAY);
calendar = DateUtils.truncate(calendar, Calendar.DAY_OF_MONTH);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

shudnt this be DAY_OF_WEEK?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No, that gives an error. That's why first I am rounding to start of week, and then using truncate to get rid of hours, minutes etc.

@Amareshwari
Copy link
Contributor

Does TestCubeRewriter.testQueryWithNow need change?

Otherwise code changes look good.

@ghost
Copy link
Author

ghost commented Sep 23, 2014

TestCubeRewriter.testQueryWithNow doesn't have to be changed since it is checking that candidate tables are not available. All tests in TestCubeRewriter are passing. I am running tests on the entire cube.* package, will update pull request in case of any failures.

@ghost
Copy link
Author

ghost commented Sep 23, 2014

Tests passing.
Merging.

ghost pushed a commit that referenced this pull request Sep 23, 2014
Allow user specified granularity in relative time ranges
@ghost ghost merged commit 73258b7 into InMobi:develop Sep 23, 2014
This pull request was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants