i have a database table in MS SQL 2008 with some values like following,
id value
1 0
2 15
3 35
4 48
5 55
i want to show gap between 2 value rows in labels (or in any other way that u propose).
like, 15-0 = 15 -> 15 in a label
35-15=20 -> 20 in another label
i tried to get the whole table values to a data set in the code behind.and then read two by two,reduce them and
show them in a table.
But it gives me an exception becoz there is no any row to substract from the last row..
please give me a better solution for this...
Thank you...

Pankaj PandeyRank #642 · 3.7K reputationPosted Jul 2, 2013, 1:27 AM EDT
Iftikar HussainRank #423 · 5.9K reputationPosted Jul 1, 2013, 10:42 PM EDT
Write a stored procedure to return the difference as shown below
Regards,
Iftikar