i fetch record from database in resultset object.i've to go to last record,so when i use resultset.last() it throws SQL exception saying resultset is TYPE_FORWARD_ONLY.i tried to change this attribute using setFetchDirection(ResultSet.Unknown_Direction) but same exception appears.please help me how can i directly get to last record. khurram mirza