how to find accumulated depriciation
I am calculating accumulated depriciation and NBV .I am using the following query .But for each asset there are multiple rows available .I need one row which i will show in my report.
select (fds.deprn_reserve) accumulated_depriciation,(fb.cost-fds.deprn_reserve)NBV
from fa_books fb,
fa_deprn_summary fds
where fb.asset_id=fds.asset_id
and fb.book_type_code=fds.book_type_code
and fds.ASSET_ID=fb.asset_id
and fb.date_ineffective is null
and fb.ASSET_ID=input_assetid
How i will filter the other rows?..probably they are available because multiple time depriciation has run...