Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Pull Data from preivous row, same data field

Status
Not open for further replies.

scullysiz

Technical User
Jul 11, 2002
3
US
Is there any way to grab data from the previous row, same data field? For example in the data below:

Vehicle Tag # Wk st dt Wk end Dt End Miles Prev End Miles
abcde 5/5/11 5/11/11 10,100
abcde 5/12/11 5/18/11 10,500 10,100

Is there any way to grab the 5/5 End ODM and show it as the previous week Miles on the same row as 5/12/11 data?

Thanks,
Susan
 
Check out the 'lag' and 'lead' functions. They are analytical (OLAP) functions added as standard Cognos functions.

Ties Blom

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top