161: --
162: -- syoung: performance tuning: count(*) to count(1).
163: -- and inserted rownum condition.
164: select count(1) into lv_count
165: from fa_leases
166: where lease_id = X_Lease_Id
167: and rownum < 2;
168: --
169: if lv_count > 0 then
293: lease_type,
294: asset_life,
295: lease_term,
296: currency_code
297: from fa_leases ls
298: where ls.lease_id = X_Lease_Id;
299: LS_ROW LS_CUR%ROWTYPE;
300: h_status boolean := false;
301: update_error exception;
304: if X_Lease_Id is not null then
305: OPEN LS_CUR;
306: FETCH LS_CUR INTO LS_ROW;
307:
308: FA_LEASES_PKG.UPDATE_ROW(
309: X_Rowid => LS_ROW.Row_id,
310: X_Lease_Id => LS_ROW.Lease_Id,
311: X_Lease_Number => LS_ROW.Lease_Number,
312: X_Lessor_Id => LS_ROW.Lessor_Id,