Click here to Skip to main content
10,500,000 members (61,348 online)
Click here to Skip to main content
Add your own
alternative version


4 bookmarked
Posted 17 Apr 2014

Intelligent Workbook for Generating Basic DAX Formulas used for Time Series Analysis of Measures

, 22 Aug 2014
Rate this:
Please Sign up or sign in to vote.
Intelligent workbook for generating time series DAX

The Problem

Assume you have a lot of measures - Gross Sales, Net Sales, Guest Counts, Discount Amounts, etc.

You need to now generate DAX for time series analysis against these measures, i.e., week to date, month to date, prior year comparisons, etc.

The realization is that the time series DAX queries for the measures would be similar regardless of the measure.


So, instead of manually having to re-write DAX queries from scratch for each time series analysis, for that measure, this workbook will take basic information about the measure as input and then output the time series dax.

The intelligent spreadsheet uses pre-programmed formulas to output the DAX queries in a different tab. See sample outputs below for the Total Gross Sales (TGS) measure.


I've attached the "intelligent" workbook for use. This is a work in progress. If some of the formulas are not right, please feel free to update it once it's generated. And send suggestions to me so that I can make the workbook smarter. I would advise you use the queries generated as a starting point for writing your own, instead of relying on it as final.

Also, there are hidden tabs in the workbook that are used for calculations. You can unhide those if you want to go under the hood.

Again thanks. I'm looking forward to suggestions.


This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


About the Author

Technical Lead
United States United States
I'm a developer, blogger and all around technology enthusiast. He writes and stays abreast with the latest innovative ideas, news, and trends.

You may also be interested in...


Comments and Discussions

-- There are no messages in this forum --
Permalink | Advertise | Privacy | Terms of Use | Mobile
Web02 | 2.8.170915.1 | Last Updated 22 Aug 2014
Article Copyright 2014 by FLouis38
Everything else Copyright © CodeProject, 1999-2017
Layout: fixed | fluid