David Youngquist 3 Posted January 25, 2022 Share Posted January 25, 2022 I am interested in comparing average data from current week (last 7 days) and the week prior (7 days before current week). I am able to calculate out the current week using the following calc column: Current Week = case when [end]>DateAdd("dd",-7,DateTimeNow()) then Avg([Count(emission_rate)]) OVER (Intersect([node_name],LastPeriods(7,[end]))) else NULL END Prior Week = (I've tried using the following) case when [end]>DateAdd("dd",-14,DateTimeNow()) and [end] Link to comment Share on other sites More sharing options...
Fredrik Rosell 3 Posted January 27, 2022 Share Posted January 27, 2022 Hello David, This question appears to be very similar to the other one you created around the same time - https://community.tibco.com/questions/how-do-i-create-calculated-column-prior-week-dd-datetimenow - where there is now an active discussion. Unless you see a need for this question to remain as well, I suggest that further activities are done in the other question. Best Regards Fredrik Rosell Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now