I have this table with n number of rows. I need to be able to calculate the difference between the max row and the one previous to that.

To get the max rowid, I use the following syntax:
select * from tablename
where rowid=(select max(rowid) from tablename)

But I don't know how to select the row that is immediately previous to the max(rowid): i.e. max(rowid) - 1.
(not the minimum rowid)

Anyone knows the syntax for that, please let me know!

Thanx in advance
Fiona