Quantcast
Channel: Transact-SQL forum
Viewing all articles
Browse latest Browse all 23857

Value from Previous Date

$
0
0

Hey guys,

I'm new to this discussion board and quite new to BI and MSSQL.

Currently I have to solve a problem for homework in university and I don't know how to do it.

I have to build reports using Excel PowerPivot with Data out of MS SQL Server 2008. The database contains Printer-Device-Data like Errors and PageCounter.

Here is an Example of the Data:

DateIdSeverityPageCountDeviceIdErrorId
13.04.2012 00:00:001520131631
10.07.2012 00:00:001560621631
13.11.2012 00:00:004639071631
28.11.2012 00:00:004644921631
12.09.2012 00:00:004615241631
29.11.2012 00:00:004645731631

For explanation:

DateId is the Date, when an Error was raised, Severity is the Severity of the Error in general. DeviceId is the identifying Key for the Printer-Device. ErrorId identifies the Error and PageCount is the Total Page COunter at the moment when the Error raised.

My Problem is, that this counter shows the actual value. I want to extract the amount of pages, prinded between the two dates.

Any Ideas, how I can do this?

I tried to use DAX Formula with EARLIER() and PREVIOUSDAY(), but this didn't work.

Please help me.

Thank you!


Viewing all articles
Browse latest Browse all 23857

Trending Articles