Operating Lease

Dear Experts,
Our company would like to introduce Operating Lease. I have read about customizing this operating lease but at the moment, it is still not working.
FYI - I have activated cost accounting depreciation area 20 (post to GL inactive). I also have created the leasing type - operating lease with the necessary doc type, posting key. I have also have created the asset class which is pointing to only depreciation area 20 with no depreciation. This asset class has leasing information - the vendor, amount, term and etc.
However, when I post a cost to this asset (created using the above asset class), I can only post in AA module with no corresponding entry in FI-AP (because post to GL is inactive). (btw - I am not able to post via FI - I have tried using standard transaction type for leasing as well as customised). I am just wondering how this can relates with - one time posting and clearing using recurring document (read this in SAP Document - Posting acquisition of Lease Asset (Operating Lease) http://help.sap.com/saphelp_erp60_sp/helpdata/en/4f/71fd71448011d189f00000e81ddfac/frameset.htm -  if the debiting the assets does not hitting FI. I am also wondering at what point that I can debit the expenses (with appropriate cost center). I have tried a few scenario with different posting key to get the asset to be posted as statistical (some notes are tallking about statistical assets) and actual to expense, but still does not work. I also wondering how the payment to vendor will be updated in Asset Master.
I really appreciate some clue or any notes that I can read on this subject.
Thanks.
Regards
Fauzi

This is what I get from SAP documentation:
Post the asset acquisition using a transaction type that only posts to cost-accounting depreciation areas.
In FI, create a recurring document for lease payments.
After invoices are posted in the system, payment can be processed using the FI payment program.
How you process the cancellation of a lease depends on the lease method:
In the case of a capital lease you determine if the asset is being purchased or returned. If the asset is being purchased, you post an asset transfer, if it is being returned, you post a retirement.
In the case of an operating lease, you simply delete the master record for the statistical asset. The rental agreement must also be closed in FI (flag the recurring entry document for deletion).
If the lease is canceled ahead of time, you have to reverse the future liabilities that are due.

Similar Messages

  • Operating leasing configuration

    Hi all,
    I have a customer that has operating leasing. They want to have better control of their leasing costs. I have search on internet and found that there is possible to crate assets for operating leasing as follow:
    I configure a new asset class, 6000 and then create a new asset in AS01. In AS01 i tell:
    - Agreement number
    - Agreement date
    - Notice date
    - Lease start date
    - Lease lenght
    - Type
    - Base value as new
    - Purchase price
    - No lease paymen
    - Payment cycle
    - Lease payment
    - Annual rate of interest
    I then choose the depreciation areas tab page and select deact field for depreciation areas.
    Then I can see the value in transaction S_ALR_87011992.
    But how do I do when I then got invoices, how do I link the costs to this asset, so I can see that the cost belong to this asset? Do I have to create statistical orders that has the same number as the asset?
    Is this the best solution for my customer, to create a new asset class and see the leasing among the other assets? If not what else can be a solution, for example only statistical orders?
    They also want to have better control over the accruals of leasing. Do you have a better solution then transaction FBS1 and F.82?
    Thanks in advance!
    Regards Lisa

    Hi Lisa
    Please find answers to your questions
    1. Okej, but if I have acquasition to this asset for 108 000 EUR for example and then run depreciation. Will my value of that asset still be 108 000, all time and the only thing that will be posten when I run the depreciation is the interest?
    When you run depreciation, the value of asset will reduce as per percentage specified on depreciation key. Interest which you would normally pay on leasing any particular asset will be calculated and posted accordingly.
    2.If I will lease this asset for 3 years, do I have to do anything after this tre years or does the system gives the value of this asset 0 EUR after the lease period automatic?
    If you ahve set useful life as 3 years in asset master record and charging depreciation on useful life then asset value will become 0 at end of 3 years.
    3. What does they mean with purchase price, is that price after the lease period?
    purchase price  is the price at which you have purchased the leased asset.
    4. - What happens to the lease payment. Does that payment posts also when we run depreciation, as the interest?
    Lease payment is not posted through Asset accounting. it should be posted from FI.
    hope tht helps.
    Thanks
    Sanjeev

  • Post expense of operating leased asset

    Dear experts
    i want to know how to post the operating leased asset expense periodocally ???
    is there a way to post it automatically or even how to post it manually

    any help experts??????

  • Refx lease rental cash flow for non-cancellable contracts

    Dear Refx Group,
    As per Accounting Standard (AS) 19 - Leases, the lessee should make the following disclosures for operating leases:
    a) the total of future minimum lease payments under non-cancellable operating leases for each of the  following periods:
    ('i) not later than one year;
    (ii) later than one year and not later than five years;
    (iii) later than five years;
    Is there any standard report or any methodology whereby we can get the above information.
    Regards,
    Sudhir Chattapan

    Dear Refx Group,
    As per Accounting Standard (AS) 19 - Leases, the lessee should make the following disclosures for operating leases:
    a) the total of future minimum lease payments under non-cancellable operating leases for each of the  following periods:
    ('i) not later than one year;
    (ii) later than one year and not later than five years;
    (iii) later than five years;
    Is there any standard report or any methodology whereby we can get the above information.
    Regards,
    Sudhir Chattapan

  • Automatically post the lease rental charges for oprating lease asset using

    hi
    i tried that way which you have given but the wht tac and tax code i am not getting
    anyone can send  the coding accordingly
    the requirement is like that
    Company code (BUKRS)  - Mandatory 
                 Asset class (ANLKL)  - Mandatory -
                 Vendor (Leasing company) (LEAFI) - Mandatory
                 Business Place (BUPLA)
                 WHT Tax code (QSSKZ)
                 Tax code  (MWSKZ)
                 Document type (BLART) - Mandatory
                 Document Date (BLDAT) ) - Mandatory
                 Posting Date (BUDAT) - ) - Mandatory
                 Reference (XBLNR) - ) - Mandatory
                 Document Header text (BKTXT) - ) - Mandatory
    Logic: 
    Pass the values in ANLA for .
    Company code-BUKRS
    Asset Class-ANLKL
    Vendor (Leasing company)-LEAFI
    Get ANLA-ANLN1 and Lease payment (ANLA-LEGEB) from ANLA table
    where Leasing Type ANLA-LEART=02(Operating Lease) . Check Deactivation date ANLA-DEAKT=space OR Posting date in selection BUDAT<= ANLA-LKDAT
        After getting all Assets related to selection vendor post the lease rental document by calling F-02 transaction code (Check BAPI available)
    The program should post the lease payment amount by crediting vendor with sum of lease payment for all assets selected for this vendor and debiting the individual lease payments to u2026u2026. 
    Checks at the time of posting:
    1. Pass the Business place value in to Section code also
    2. Ensure except WHT code entered in selection screen, all the other WHT codes are deleted at the time of posting.
    3. At the time of posting document in the lease rental for Asset line item text it should fill with u201CLease rent for Asset numberu2026u2026u2026for the month of u2026.u201D
    Edited by: jnanaranjan.paikray on Jul 30, 2010 9:26 AM

    hi raj
    i got it
    thk for everything

  • Making Lease Payments

    Hi this is my first post here.  My company is implementing Asset Management and Lease Accounting.  They've recorded an operating lease that created the vendor payable.  This payable has a line item for each payment, but they're all on the same document.  Because it's the same document number, F110 won't pick this line item up in the payment run.  How do we make the Lease payments?  There's an example attached.

    Hi Mukthar,
    Do we need to setup an installment payment terms for this process?  The current payment term isn't an installment.  It's setup to pay on zero days from the document date (Due immediately).
    The single document number 110000060, has 48 vendor line items.  Each line item has a different baseline date.  These baseline dates were driven from the monthly installments setup in the AA module.
    You can see here the different line item baseline dates.  If the payment term is setup correctly, will each of these line items be cleared monthly when the payment run is made through F110?
    Itm PK Account      Account short text   Tx           Amount     Amount in LC LCurr Bline Date
      1 70 6561030000   000000000016 0000             40,961.91        40,961.91  INR
      2 40 7881000000   LT Lease Obligations           7,038.09         7,038.09  INR
      3 31 337375                                      1,000.00-        1,000.00- INR   08/25/2013
      4 31 337375                                      1,000.00-        1,000.00- INR   09/22/2013
      5 31 337375                                      1,000.00-        1,000.00- INR   10/27/2013
      6 31 337375                                      1,000.00-        1,000.00- INR   11/24/2013
      7 31 337375                                      1,000.00-        1,000.00- INR   12/22/2013
      8 31 337375                                      1,000.00-        1,000.00- INR   01/26/2014
      9 31 337375                                      1,000.00-        1,000.00- INR   02/23/2014
    10 31 337375                                      1,000.00-        1,000.00- INR   03/23/2014
    11 31 337375                                      1,000.00-        1,000.00- INR   04/27/2014
    12 31 337375                                      1,000.00-        1,000.00- INR   05/25/2014
    13 31 337375                                      1,000.00-        1,000.00- INR   06/22/2014
    14 31 337375                                      1,000.00-        1,000.00- INR   07/27/2014

  • Lease Accounting Scenario

    Dear:
                We have Lease accounting for assets configured in Organization Now the leasing process has changed. Management now receives funds from bank for the value of asset being purchased i-e finance lease. AS-IS process (currently running ) and TO-BE (what we want ) are given
    Where lessor don't transfer funds for car in which accounting entries are as follows
    AS-IS Process
    At inception:
    Security deposit               Dr.
                                    Bank                      Cr.
    Leased Asset                     Dr.
                                    Lease Liability    Cr.
    Monthly installment:
    Lease Liability                    Dr.
    Lease interest                   Dr.
                                    Bank                      Cr.
    TO-BE Process
    ·         We want this to be used Where lessor transfer funds for car. Please advice on the feasibility of automating this process in lease asset module. Specially the first entry is confusing. How will we cater it in AA module or passing a manual JV will be a solution. Please guide.
    At inception:
    Bank                                      Dr.
    Security deposit               Dr.
                                    Lease Liability                    Cr.
    Monthly installment:
    Lease Liability                    Dr.
    Lease interest                   Dr.
                                    Bank                      Cr.
    Regards
    Edited by: Atif Farooq on Jul 23, 2011 10:00 AM

    Just a few question to clarify your scenario.
    Your organization acquired the cars from the car dealership or manufacturer?
    Your organization is the (lessor), and there are customers (lessees) who lease your cars?
    When customers make payments, your bank receives the money and gives it to your organization?
    If these 3 questions all have answer of Yes, then you have to decide what accounting rules you wish to follow.  US GAAP, IFRS, something else.  The reason must decide on accounting rules is because leasing rules are changing, and early adoption of the new rules may already be in place in your firm.
    To get SAP advice, you have to be able to say whether or not this is a capital financing lease or is an operational lease.
    If it is a capital financing lease (for your customer/buyer) then in the substance of the actual transaction you have already sold the car according to US GAAP existing rules.  You do not have a capital asset (car) in your AA sub-ledger any longer.  Instead you have a long-term lease receivable for the present value of all future payments to arrive.  The current year portion of the amount will be classified as current year.  As payments come in, you reduce the current receivable by the previously recorded present value amount, and you credit imputed effective interest income for the difference to balance your entry with cash.
    But if the leases are operational leases, then you will depreciate the cars while you receive lease and imputed effective interest revenue.  You will get the cars back with more than just small residual value left.

  • Post the lease rental charges for oprating lease asset using  bdc  for f-02

    hi any can send me the programed for t code f-02
    for post the lease rental charges for operating lease asset using  bdc  for f-02
    This is not a place where you can get your entire work done by others. Please put some effort from your side before turning to the forums for help. Thread locked.
    Locked by: kishan P on Aug 24, 2010 5:47 PM

    hi any can send me the programed for t code f-02
    for post the lease rental charges for operating lease asset using  bdc  for f-02
    This is not a place where you can get your entire work done by others. Please put some effort from your side before turning to the forums for help. Thread locked.
    Locked by: kishan P on Aug 24, 2010 5:47 PM

  • Any implementations of CRM leasing in manufacturing company

    Hello All,
    I know that CRM leasing is only used with typical leasing company, but wanted to check with you guys if there was any implementation done for manufacturing company for CRM leasing who does leasing on its own with single legal entity, how is accounting and delivery is effected.
    or are there any restrictions in implementing CRM leasing with OEMS?
    any help here is highly appreciated.
    Thanks

    Additional question, In case of Operating Lease why do we split Repayment amount during Term period of the contract, in this case the lessee is not buying the Asset right, he will return the Asset to the Lessor anyways.

  • Lease Assets Management

    Hi Gurus,
    Thanks in advance
    I need Lease Assets Management in SAP configuration documents.
    If any body have please send me on following mail ID : [email protected]
    Thanks

    Hi deepika.... the following notes may useful to u ..
    The "Leased Assets" scenario describes the management of leased assets from the standpoint of the lessee.
    Leased assets create special accounting requirements for the lessee, as compared to assets that an enterprise purchases or produces itself. During the term of the lease, leased assets remain the property of the lessor or manufacturer. They represent, therefore, a special form of rented asset. Such assets are legally and from a tax perspective the responsibility of the lessor, and are not relevant for assessing the value of the asset portfolio of the lessee. However, in certain countries, you are nonetheless required to capitalize leased assets, depending on the type of financing.
    This scenario makes it possible to handle different types of leased assets differently. Depending on legal restrictions, you can capitalize and depreciate leased assets (capital lease) or post their rent expense periodically to the profit and loss statement (operating lease).
    There are different ways of handling the values of leased assets in the system. Depending on legal requirements and the conditions of the lease, there are two different options:
    You have to capitalize and depreciate certain leased assets (capital lease).
    You treat others as periodic rent expense, which flows into the profit and loss statement (operating lease).
    This second type is not relevant to the fixed assets of the lessee. It is therefore sufficient to do one of the following:
    Manage operating leases as statistical assets in the Asset Accounting component (with no active depreciation areas)
    Manage them only as cost-accounting values (or for group accounting) in the corresponding depreciation areas
    There is a special report on rent liability that can be used for all types of leased assets (see below).
    You can also manage insurance values for purely statistical leased assets (without depreciation areas). You enter a manual insurance value and an index series for the leased assets in the asset master record. You obtain reports on these values using the standard report for insurance values.
    <b>Capital Lease Method</b>
    Leased assets can be capitalized in the Asset Accounting component using the capital lease method. The system calculates the acquisition value from the present value of the future lease payments in the leasing agreement. To be able to determine the future burden of payment, you need to maintain the following leasing conditions in the asset master records:
    Amount of lease payment
    Number of payments
    Payment cycle
    In order to calculate present value, also enter an interest rate. The system requires that you post a leasing partner as a vendor in the asset master record at the time of the acquisition posting (opening posting).
    <b>Periodic Posting</b>
    The depreciation posting program posts the depreciation of leased assets and the write-off of the interest. You can use any depreciation key. The standard R/3 System includes a special depreciation key, in which the depreciation amounts correspond to the present value of the periodic leasing payments (LEAS). Using this key, interest is determined as the difference between the leasing payments and the present value.
    <b>Calculation of Present Value</b>
    The present value of the leased asset is calculated on the basis of the following specifications:
    g : Amount of lease payment
    i : Annual interest rate
    n : Number of lease payments
    r: Leasing cycle (for example, 3 = quarterly, 6 = semiannual)
    m : Number of periods in a year
    q : Period interest factor = 1 + ( i / 100 * r / m)
    If payment is made at the beginning of the period, the present value then results from the following formula:
    Present value = g + g * q** (n-1) - 1 / (q**n-1 * (q - 1))
    With payment at the end of the payment period, on the other hand, the present value is calculated as follows:
    Present value = g * ( q*n - 1) / ( q*n * ( q - 1))
    Example
    g : 100
    i: 10.000 %
    n: 20
    r: 3
    m: 12
    q: 1 + (10.000 / 100 * 3 / 12) = 1.025
    Present value at the beginning of the payment period:
    100 + 100 * (1.025*19 - 1) / (1.025*19 * (1.025 - 1)) = 1597.89
    Present value at the end of the payment period:
    100 * (1.025*20 - 1) / (1.025*20 * ( 1.025 - 1)) = 1558.92
    <b>Reports</b>
    There is a standard report in the system for determining future leasing liability (especially in regard to leased assets that are not capitalized). The report displays for each leased asset:
    The payments already made
    The payments due up to the date of the report
    The total lease payments to be made for the asset
    You can create a totals list with cumulative values for each fiscal year and company code. In order for the report to work properly, you must make sure that the following leasing conditions are properly maintained in the asset master record:
    Start date of the lease
    Payment information (lease payment amount, payment cycle, number of payments)
    Leasing type
    Using the APC by acquisition year indicator, you can display the theoretical acquisition value of leased assets according to acquisition year. This statistical analysis is required in some countries for financial reports. The system uses the base new value that is specified in the asset master record in the leasing information. The acquisition year is determined from the start date of the lease.
    <b>Implementation Considerations
    General Tips</b>
    If you want to manage capitalized leased assets in the system, follow these steps:
    Define leasing types in Customizing for Asset Accounting with the specifications for posting asset acquisitions.
    Create special asset classes and account allocations for your leased assets.
    Define depreciation areas, in which you plan to capitalize leased assets using the capital lease procedure, so that they manage interest that can be posted with the depreciation posting program.
    Activate the depreciation areas, in which the leased assets will be capitalized and depreciated, in these asset classes.
    Assign a leasing type to the asset master records for leased assets.
    Maintain the information and conditions of the leasing agreement in the master records of the leased assets. Specify an interest rate for calculating the present value and determine whether the lease payments should be made at the beginning of the payment period or at the end of the payment period.
    Post the acquisition of a leased asset with the display transaction for asset master data.
    <b>Leased Asset acquisition</b>
    The "acquisition of a leased asset" is considered for our purposes to be the entry of the leased asset in the FI-AA System. This does not necessarily mean that the leased asset must be capitalized. You can enter a leased asset simply to manage purely statistical data. You handle the leased asset as a master record, with no values in the book or tax depreciation areas.
    Posting the acquisition of a leased asset may be necessary for one of the following reasons:
    You have received a new leased asset (goods receipt).
    You need to change the way bookkeeping is handled for a leased asset due to a change in the conditions of the lease.
    You need to post a leased asset to a new asset master record due to a transfer.
    <b>Process Flow</b>
    Before posting the acquisition of the leased asset, you must determine the bookkeeping method to be used, either:
    Capitalization of the leased asset to fixed assets, with the present value of the future lease payments and depreciation of the present value (capital lease)
    Statistical management of the leased asset (no capitalization), and direct posting of the lease payments as rental expense in the profit and loss statement (operating lease)
    For more details.....
    http://help.sap.com/saphelp_47x200/helpdata/en/4f/71fd71448011d189f00000e81ddfac/frameset.htm
    If u satisfied... please assif=gn me points...
    Dasharathi

  • Lease Assets

    Hi there,
    Can you please explain how a capital lease works.  I have configured an operational lease and it works perfectly - updates the vendor account with all the payments due and the asset is not capitilised.
    What happens with the Capitilised lease - on creating the master data in AS01 does it automatically create the capitilization of the asset? Is there another posting we have to do eg an acquisition? does it create any line items in the vendor account?
    i am really interested and would like to know.
    Thank you
    Regards
    Jacqui

    Hi,
    Please check this and create asset as suggested by inputing the values in the tab for leasing.
    http://help.sap.com/saphelp_46c/helpdata/EN/48/ae9b9da63511d3a7320060087d1a6b/content.htm
    Trust this helps much!
    Cheers!

  • SUM two ROWS in the SAME Table

    Hi,
    I have a problem with this issue. I want to sum two rows from the same table, but I don´t know how to do that. I tried to do it with CTE, but always I get the same error "Ambiguous". I would like to ask you, if there is other manner to get that
    data (sum two rows) and if it is possible to see examples about it.
    Thank you  in advance

    Hi Vaibhav,
     I leave you my scrip:
    USE Modelling
    GO
    --TABLE Aer_Lingus_Income_Statement
    IF OBJECT_ID('Aer_Lingus_Income_Statement') IS NOT NULL
    DROP TABLE Aer_Lingus_Income_Statement
    GO
    CREATE TABLE Aer_Lingus_Income_Statement
    ID [nvarchar](255) NOT NULL,
    Name_Account [nvarchar](255) NULL,
    Company [nvarchar](255) NULL,
    Level0_Account [nvarchar](255) NULL,
    Level1_Account [nvarchar](255) NULL,
    Level2_Account [nvarchar](255) NULL,
    Level3_Account [nvarchar](255) NULL,
    Level4_Account [nvarchar](255) NULL,
    Level5_Account [nvarchar](255) NULL,
    Level6_Account [nvarchar](255) NULL,
    Level7_Account [nvarchar](255) NULL,
    Level8_Account [nvarchar](255) NULL,
    Year_2006 decimal (15,2) null,
    Year_2007 decimal (15,2) null,
    Year_2008 decimal (15,2) null,
    Year_2009 decimal (15,2) null,
    Year_2010 decimal (15,2) null,
    Year_2011 decimal (15,2) null,
    Year_2012 decimal (15,2) null,
    Year_2013 decimal (15,2) null,
    GO
    ALTER TABLE Aer_Lingus_Income_Statement
    ADD CONSTRAINT PK_Aer_Lingus_Income_Statement PRIMARY KEY (ID)
    GO
    INSERT INTO Aer_Lingus_Income_Statement
    SELECT *
    FROM Aer_Lingus_data_Income
    IF OBJECT_ID('Aer_Lingus_Income_Statement_Historic') IS NOT NULL
    DROP VIEW Aer_Lingus_Income_Statement_Historic
    GO
    CREATE VIEW Aer_Lingus_Income_Statement_Historic
    as
    Select Level0_Account , sum(Year_2006) as Y2006, sum (Year_2007) as Y2007, sum (Year_2008) as Y2008, sum (Year_2009) as Y2009, sum (Year_2010) as Y2010,
    sum (Year_2011) as Y2011, sum (Year_2012) as Y2012, sum (Year_2013) as Y2013
    FROM Aer_Lingus_data_Income
    Where Level0_Account ='Revenue'
    Group by Level0_Account
    UNION ALL
    Select Name_Account , sum(Year_2006) as Y2006, sum (Year_2007) as Y2007, sum (Year_2008) as Y2008, sum (Year_2009) as Y2009, sum (Year_2010) as Y2010,
    sum (Year_2011) as Y2011, sum (Year_2012) as Y2012, sum (Year_2013) as Y2013
    FROM Aer_Lingus_data_Income
    Where Name_Account= 'Passenger revenue' and Level0_Account ='Revenue'
    Group by Name_Account
    UNION ALL
    Select Name_Account , sum(Year_2006) as Y2006, sum (Year_2007) as Y2007, sum (Year_2008) as Y2008, sum (Year_2009) as Y2009, sum (Year_2010) as Y2010,
    sum (Year_2011) as Y2011, sum (Year_2012) as Y2012, sum (Year_2013) as Y2013
    FROM Aer_Lingus_data_Income
    Where Name_Account= 'Ancillary revenue' and Level0_Account ='Revenue'
    Group by Name_Account
    UNION ALL
    Select Name_Account , sum(Year_2006) as Y2006, sum (Year_2007) as Y2007, sum (Year_2008) as Y2008, sum (Year_2009) as Y2009, sum (Year_2010) as Y2010,
    sum (Year_2011) as Y2011, sum (Year_2012) as Y2012, sum (Year_2013) as Y2013
    FROM Aer_Lingus_data_Income
    Where Name_Account= 'Other revenue' and Level0_Account ='Revenue'
    Group by Name_Account
    UNION ALL
    Select Name_Account , sum(Year_2006) as Y2006, sum (Year_2007) as Y2007, sum (Year_2008) as Y2008, sum (Year_2009) as Y2009, sum (Year_2010) as Y2010,
    sum (Year_2011) as Y2011, sum (Year_2012) as Y2012, sum (Year_2013) as Y2013
    FROM Aer_Lingus_data_Income
    Where Name_Account= 'Cargo revenue' and Level0_Account ='Revenue'
    Group by Name_Account
    UNION ALL
    Select Level0_Account , sum(Year_2006) as Y2006, sum (Year_2007) as Y2007, sum (Year_2008) as Y2008, sum (Year_2009) as Y2009, sum (Year_2010) as Y2010,
    sum (Year_2011) as Y2011, sum (Year_2012) as Y2012, sum (Year_2013) as Y2013
    FROM Aer_Lingus_data_Income
    Where Level0_Account ='Operating expenses'
    Group by Level0_Account
    UNION ALL
    Select Level1_Account , sum(Year_2006) as Y2006, sum (Year_2007) as Y2007, sum (Year_2008) as Y2008, sum (Year_2009) as Y2009, sum (Year_2010) as Y2010,
    sum (Year_2011) as Y2011, sum (Year_2012) as Y2012, sum (Year_2013) as Y2013
    FROM Aer_Lingus_data_Income
    Where Level1_Account ='Staff costs' and Level0_Account ='Operating expenses'
    Group by Level1_Account
    UNION ALL
    Select Level1_Account , sum(Year_2006) as Y2006, sum (Year_2007) as Y2007, sum (Year_2008) as Y2008, sum (Year_2009) as Y2009, sum (Year_2010) as Y2010,
    sum (Year_2011) as Y2011, sum (Year_2012) as Y2012, sum (Year_2013) as Y2013
    FROM Aer_Lingus_data_Income
    Where Level1_Account ='Depreciation, amortisation and impairment' and Level0_Account ='Operating expenses'
    Group by Level1_Account
    UNION ALL
    Select Name_Account , sum(Year_2006) as Y2006, sum (Year_2007) as Y2007, sum (Year_2008) as Y2008, sum (Year_2009) as Y2009, sum (Year_2010) as Y2010,
    sum (Year_2011) as Y2011, sum (Year_2012) as Y2012, sum (Year_2013) as Y2013
    FROM Aer_Lingus_data_Income
    Where Name_Account ='Aircraft operating lease costs' and Level0_Account ='Operating expenses'
    Group by Name_Account
    UNION ALL
    Select Name_Account , sum(Year_2006) as Y2006, sum (Year_2007) as Y2007, sum (Year_2008) as Y2008, sum (Year_2009) as Y2009, sum (Year_2010) as Y2010,
    sum (Year_2011) as Y2011, sum (Year_2012) as Y2012, sum (Year_2013) as Y2013
    FROM Aer_Lingus_data_Income
    Where Name_Account ='Fuel and oil costs' and Level0_Account ='Operating expenses'
    Group by Name_Account
    UNION ALL
    Select Name_Account , sum(Year_2006) as Y2006, sum (Year_2007) as Y2007, sum (Year_2008) as Y2008, sum (Year_2009) as Y2009, sum (Year_2010) as Y2010,
    sum (Year_2011) as Y2011, sum (Year_2012) as Y2012, sum (Year_2013) as Y2013
    FROM Aer_Lingus_data_Income
    Where Name_Account ='Maintenance expenses' and Level0_Account ='Operating expenses'
    Group by Name_Account
    UNION ALL
    Select Name_Account , sum(Year_2006) as Y2006, sum (Year_2007) as Y2007, sum (Year_2008) as Y2008, sum (Year_2009) as Y2009, sum (Year_2010) as Y2010,
    sum (Year_2011) as Y2011, sum (Year_2012) as Y2012, sum (Year_2013) as Y2013
    FROM Aer_Lingus_data_Income
    Where Name_Account ='Airport charges' and Level0_Account ='Operating expenses'
    Group by Name_Account
    UNION ALL
    Select Name_Account , sum(Year_2006) as Y2006, sum (Year_2007) as Y2007, sum (Year_2008) as Y2008, sum (Year_2009) as Y2009, sum (Year_2010) as Y2010,
    sum (Year_2011) as Y2011, sum (Year_2012) as Y2012, sum (Year_2013) as Y2013
    FROM Aer_Lingus_data_Income
    Where Name_Account ='En-route charges' and Level0_Account ='Operating expenses'
    Group by Name_Account
    UNION ALL
    Select Name_Account , sum(Year_2006) as Y2006, sum (Year_2007) as Y2007, sum (Year_2008) as Y2008, sum (Year_2009) as Y2009, sum (Year_2010) as Y2010,
    sum (Year_2011) as Y2011, sum (Year_2012) as Y2012, sum (Year_2013) as Y2013
    FROM Aer_Lingus_data_Income
    Where Name_Account ='Distribution costs' and Level0_Account ='Operating expenses'
    Group by Name_Account
    UNION ALL
    Select Name_Account , sum(Year_2006) as Y2006, sum (Year_2007) as Y2007, sum (Year_2008) as Y2008, sum (Year_2009) as Y2009, sum (Year_2010) as Y2010,
    sum (Year_2011) as Y2011, sum (Year_2012) as Y2012, sum (Year_2013) as Y2013
    FROM Aer_Lingus_data_Income
    Where Name_Account ='Ground operations, catering and other operating costs' and Level0_Account ='Operating expenses'
    Group by Name_Account
    UNION ALL
    Select Level1_Account , sum(Year_2006) as Y2006, sum (Year_2007) as Y2007, sum (Year_2008) as Y2008, sum (Year_2009) as Y2009, sum (Year_2010) as Y2010,
    sum (Year_2011) as Y2011, sum (Year_2012) as Y2012, sum (Year_2013) as Y2013
    FROM Aer_Lingus_data_Income
    Where Level1_Account ='Other (gains)/losses - net' and Level0_Account ='Operating expenses'
    Group by Level1_Account
    UNION ALL
    Select Name_Account , sum(Year_2006) as Y2006, sum (Year_2007) as Y2007, sum (Year_2008) as Y2008, sum (Year_2009) as Y2009, sum (Year_2010) as Y2010,
    sum (Year_2011) as Y2011, sum (Year_2012) as Y2012, sum (Year_2013) as Y2013
    FROM Aer_Lingus_data_Income
    Where Name_Account ='Employee profit share' and Level0_Account ='Operating expenses'
    Group by Name_Account
    GO
    WITH sumasRevenue
    AS (
    SELECT Name_Account, ID
    , sum(Year_2006) AS Y2006, sum (Year_2007) as Y2007, sum (Year_2008) as Y2008, sum (Year_2009) as Y2009, sum (Year_2010) as Y2010,
    sum (Year_2011) as Y2011, sum (Year_2012) as Y2012, sum (Year_2013) as Y2013
    FROM Aer_Lingus_data_Income
    WHERE Level0_Account = 'Revenue'
    GROUP BY Name_Account, ID
    WITH ROLLUP
    , total
    AS (
    SELECT Y2006,Y2007 ,Y2008,Y2009 ,Y2010 ,Y2011 ,Y2012 ,Y2013
    FROM sumasRevenue
    WHERE Name_Account IS NULL
    sumasOperatingExpensive
    AS (
    SELECT Name_Account, ID
    , sum(Year_2006) AS Y2006, sum (Year_2007) as Y2007, sum (Year_2008) as Y2008, sum (Year_2009) as Y2009, sum (Year_2010) as Y2010,
    sum (Year_2011) as Y2011, sum (Year_2012) as Y2012, sum (Year_2013) as Y2013
    FROM Aer_Lingus_data_Income
    WHERE Level0_Account = 'Operating expenses'
    GROUP BY Name_Account, ID
    WITH ROLLUP
    , total1
    AS (
    SELECT Y2006,Y2007 ,Y2008,Y2009 ,Y2010 ,Y2011 ,Y2012 ,Y2013
    FROM sumasOperatingExpensive
    WHERE Name_Account IS NULL
    SELECT distinct ID , s.Name_Account,
    (s.Y2006* 1.0 - t.Y2006) AS [V2006] ,(s.Y2007* 1.0 -T.Y2007 ) as [V2007] , (s.Y2008* 1.0 /T.Y2008 ) as [V2008],(s.Y2009* 1.0 /T.Y2009 ) as [V2009],
    (s.Y2010* 1.0 /T.Y2010 ) as [V2010],(s.Y2011* 1.0 /T.Y2011 ) as [V2011],(s.Y2012* 1.0 /T.Y2012 ) as [V2012],(s.Y2013* 1.0 /T.Y2013 ) as [V2013]
    FROM sumasRevenue AS s , sumasOperatingExpensive AS t
    Where ID IS NOT NULL
    UNION ALL
    SELECT distinct ID,COALESCE(s.Name_Account,'NON CURRENT ASSETS') AS Name_Account ,
    sum (s.Y2006* 1.0 / t.Y2006) as V2006,sum (s.Y2007* 1.0 / t.Y2007) as V2007,sum (s.Y2008* 1.0/ t.Y2008) as V2008,sum (s.Y2009* 1.0/ t.Y2009) as V2009,sum (s.Y2010* 1.0/ t.Y2010) as V2010,
    sum (s.Y2011* 1.0 / t.Y2011) as V2011,sum (s.Y2012* 1.0/ t.Y2012) as V2012,sum (s.Y2013* 1.0/ t.Y2013) as V2013
    FROM sumasRevenue as s , sumasOperatingExpensive as t
    Where ID IS NULL and Name_Account IS NULL
    GROUP BY Name_Account, ID
    WITH ROLLUP
    select *
    from Aer_Lingus_Income_Statement_Historic
    Thank you in advance

  • What is your way to store a date in HFM?

    In financial reporting, date is also very important information at like operating lease commitement, Bank Loan, etc.
    Just want to know, what is your way to store this?
    To me, it seems can only be store at cell text. But as far as I know, there is no way to control the data quality for cell text. In this way, I am afraid some user will use mm/dd/yyyy format, some will use dd/mm/yyyy or yyyy/mm/dd format.
    Would you mind to let me know how you handle about this?
    Thanks.
    James

    {Note that abbrevations in brackets are just for short form further down the answer}
    Join Store Dim (SD) to Transaction Fact (TF) on ORG_KEY=ORG_KEY with 1 to Many cardinality
    Create an alias of Calendar Dim and call it Transaction Date (TD)
    Join TD to TF on TD.CALENDAR_KEY=TF.CALENDAR_KEY with 1 to Many cardinality
    Create a predefined condition in your universe called "Return Yesterday's Transactions" as:
    TD.DAY_DATE = trunc(sysdate-1) <-- That assumes Oracle database; use whatever is correct for yesterday for your RDBMS
    The above predefined condition when added to your data query will return only yesterday's transactions.
    However, if you want to return all the different types of sales, you would need an object for each one. To do that, you'd use a case statement. Again, using Oracle syntax, an example of MTD would be:
    SUM(CASE WHEN trunc(TD.DAY_DATE,'yyyymm') = trunc(sysdate,'yyyymm') THEN TF.amount END)
    If you have any more questions about how this approach would work please shout.
    As an alternative, you could create a time hierarchy and add scope of analysis to your report for it and enable drilling at report level.

  • Lease accounting - both capital & operation setting steps

    Hi,
    Normal FI-AA is configured in client SAP new requirement is to implement Lease accounting (both Capital & Operational). Can you suggest step by step setting required for the same (for both capital & operation) & would be great is you can through some light UAT steps (for both capital & operation) for the same.
    Thanks,
    Vishal

    I am sorry, what is the problem exactly.
    Did you provide the default value (through Property Inspector)and still it is not working?
    I have tried this and i am able to load the target table successfully.
    Here is the mapping that i created:
    1)Created mapping with a source, Mapping Input Parameter and target oprators(The source table i took is EMP table from scott schema)
    2)Mapped all the columns from source to target.
    3)For the mapping Input parameter operator i created one output variable(SAMP_DAT with DATE data type) and mapped this column to the target table
    with the value as CURRENT_DATE-10 in the expression editor provided
    4)Deployed and executed the map
    But the value for the SAMP_DAT was not loaded (it was NULL)
    5)Then i opened the property inspector for SAMP_DAT and provided the default value as CURRENT_DATE-10 and deployed and executed the map again
    And now i am able to see the data for the column SAMP_DAT in target table.
    Hope this helps
    Regards,
    Pnreddy

  • Error deleting VHD: There is currently a lease on the blob and no lease ID was specified in the request

    When attempting to delete a VHD's blob you may receive the following error:
    There is currently a lease on the blob and no lease ID was specified in the request
    While these errors are expected if a VHD is still registered as a disk or image in the portal, we have identified an issue where a lease remains even if the blob is not registered as a disk or image in the portal.
    If you receive one of these errors, first make sure the VHD is not in use:
    In the Windows Azure management portal, if the disk shows up under Virtual Machines,
    Disks, and the Attached To column is not blank, you should first remove that VM in the
    Attached To column by going to VM Instances, selecting the VM, then clicking
    Delete.
    If Attached To is blank, or the VM in the Attached To column was already removed, try removing the disk by highlighting it under
    Disks and clicking Delete Disk (this will not physically delete the VHD from blob storage, it only removes the disk object in the portal). If you have multiple pages of disks it can be easier to search for a specific disk by
    clicking the magnifying glass icon at the top right.
    If Delete Disk is grayed out, or the disk is not listed under Disks, but you still cannot reuse it or delete it, review the options below.
    Breaking the lease
    You can use the
    Lease Blob API to break the lease in this scenario, which is also available in the Windows Azure PowerShell assembly
    Microsoft.WindowsAzure.StorageClient.dll using
    LeaseAction Enumeration.
    To use the BreakLease.ps1 script to break the lease:
    Download Azure PowerShell by clicking Install under Windows here:
    http://www.windowsazure.com/en-us/manage/downloads/
    Start, Search, type Windows Azure PowerShell and open that console.
    Run Get-AzurePublishSettingsFile to launch a browser window to
    https://windows.azure.com/download/publishprofile.aspx to download the management certificate in a
    .publishsettings file in order to manage your subscription with PowerShell.
    Get-AzurePublishSettingsFile
    Run Import-AzurePublishSettingsFile to import the certificate and subscription information. Replace the path below with the full path to the .publishsettings file if you didn't save it to your
    Downloads folder. If you saved it to Downloads you can run it as-is, otherwise replace the path with the full path to the
    .publishsettings file.
    Import-AzurePublishSettingsfile $env:userprofile\downloads\*.publishsettings
    Copy the script below into a text editor such as Notepad and save it as
    BreakLease.ps1.
    Run Set-ExecutionPolicy to allow script execution:
    Set-ExecutionPolicy unrestricted
    Run BreakLease.ps1 with the URL to the VHD in order to break the lease. The script obtains the necessary storage account information, checks that the blob is not currently registered as a disk or as an image, then proceeds to break the
    current lease (if any).
    Sample output:
    BreakLease.ps1 -Uri 'http://clstorage.blob.core.windows.net/vhds/testvm1-testvm1-2012-06-26.vhd'
    Processing http://clstorage.blob.core.windows.net/vhds/testvm1-testvm1-2012-06-26.vhd
    Reading storage account information...
    Confirmed - storage account 'clstorage'.
    Checking whether the blob is currently registered as a disk or image...
    Confirmed - the blob is not in use by the Windows Azure platform.
    Inspecting the blob's lease status...
    Current lease status: Locked
    Unlocking the blob...
    Current lease status: Unlocked
    Success - the blob is unlocked.
    BreakLease.ps1
    Param([string]$Uri = $(Read-Host -prompt "Please specify a blob URL"))
    $ProgressPreference = 'SilentlyContinue'
    echo "Processing $Uri"
    echo "Reading storage account information..."
    $acct = Get-AzureStorageAccount | ? { (new-object System.Uri($_.Endpoints[0])).Host -eq (new-object System.Uri($Uri)).Host }
    if(-not $acct) {
    write-host "The supplied URL does not appear to correspond to a storage account associated with the current subscription." -foregroundcolor "red"
    break
    $acctKey = Get-AzureStorageKey ($acct.StorageAccountName)
    $creds = "DefaultEndpointsProtocol=http;AccountName=$($acctKey.StorageAccountName);AccountKey=$($acctKey.Primary)"
    $acctobj = [Microsoft.WindowsAzure.CloudStorageAccount]::Parse($creds)
    $uri = $acctobj.Credentials.TransformUri($uri)
    echo "Confirmed - storage account '$($acct.StorageAccountName)'."
    $blobclient = New-Object Microsoft.WindowsAzure.StorageClient.CloudBlobClient($acctobj.BlobEndpoint, $acctobj.Credentials)
    $blobclient.Timeout = (New-TimeSpan -Minutes 1)
    $blob = New-Object Microsoft.WindowsAzure.StorageClient.CloudPageBlob($uri, $blobclient)
    echo "Checking whether the blob is currently registered as a disk or image..."
    $disk = Get-AzureDisk | ? { (new-object System.Uri($_.MediaLink)) -eq $blob.Uri }
    if($disk) {
    write-host "The blob is still registered as a disk with name '$($disk.DiskName)'. Please delete the disk first." -foregroundcolor "red"
    break
    $image = Get-AzureVMImage | ? { $_.MediaLink -eq $blob.Uri.AbsoluteUri }
    if($image) {
    write-host "The blob is still registered as an OS image with name '$($image.ImageName)'. Please delete the OS image first." -foregroundcolor "red"
    break
    echo "Confirmed - the blob is not in use by the Windows Azure platform."
    echo "Inspecting the blob's lease status..."
    try {
    $blob.FetchAttributes()
    } catch [System.Management.Automation.MethodInvocationException] {
    write-host $_.Exception.InnerException.Message -foregroundcolor "red"
    break
    echo "Current lease status: $($blob.Properties.LeaseStatus)"
    if($blob.Properties.LeaseStatus -ne [Microsoft.WindowsAzure.StorageClient.LeaseStatus]::Locked) {
    write-host "Success - the blob is unlocked." -foregroundcolor "green"
    break
    echo "Unlocking the blob..."
    $request = [Microsoft.WindowsAzure.StorageClient.Protocol.BlobRequest]::Lease($uri, 0, [Microsoft.WindowsAzure.StorageClient.Protocol.LeaseAction]::Break, $null)
    $request.Timeout = $blobclient.Timeout.TotalMilliseconds
    $acctobj.Credentials.SignRequest($request)
    try {
    $response = $request.GetResponse()
    $response.Close()
    catch {
    write-host "The blob could not be unlocked:" -foregroundcolor "red"
    write-host $_.Exception.InnerException.Message -foregroundcolor "red"
    break
    $blob.FetchAttributes()
    echo "Current lease status: $($blob.Properties.LeaseStatus)"
    write-host "Success - the blob is unlocked." -foregroundcolor "green"
    Alternate method: make a copy of the VHD in order to reuse a VHD with a stuck lease
    If you have removed the VM and the disk object but the lease remains and you need to reuse that VHD, you can make a copy of the VHD and use the copy for a new VM:
    Download CloudXplorer. This will work with other
    Windows Azure Storage Explorers but for the sake of brevity these steps will reference CloudXplorer.
    In the Windows Azure management portal, select Storage on the left, select the storage account where the VHD resides that you want to reuse, select
    Manage Keys at the bottom, and copy the Primary Access Key.
    In CloudXplorer, go to File, Accounts,
    New, Windows Azure Account and enter the storage account name in the
    Name field and the primary access key in the Secret Key field. Leave the rest on the default settings.
    Expand the storage account in the left pane in CloudXplorer and select the
    vhds container (or if the VHD in question is one uploaded to a different location, browse to that location instead).
    Right-click the VHD you want to reuse (which currently has a stuck lease), select
    Rename, and give it a different name. This will throw the error
    could not rename…there is currently a lease on the blob… but click
    Yes to continue, then View, Refresh (F5) to refresh and you will see it did make a copy of the VHD since it could not rename the original.
    In the Azure management portal, select Virtual Machines,
    Disks, then Create Disk at the bottom.
    Specify a name for the disk, click the folder icon under VHD URL to browse to the copy of the VHD you just created, check the box for
    This VHD contains an operating system, select the drop-down to specify if it is
    Windows or Linux, then click the arrow at the bottom right to create the disk.
    After the portal shows Successfully created disk <diskname>, select
    New at the bottom left of the portal, then Virtual Machine,
    From Gallery, My Disks, and select the disk you just created, then proceed through the rest of the wizard to create the VM.
    Thanks,
    Craig

    Just to add an update to this, it looks like the namespaces have changed with the latest version of the SDK. I have updated the script to use the new namespaces, namely: Microsoft.WindowsAzure.Storage.Blob.CloudPageBlob and Microsoft.WindowsAzure.Storage.CloudStorageAccount.
    Param([string]$Uri = $(Read-Host -prompt "Please specify a blob URL"))
    $ProgressPreference = 'SilentlyContinue'
    echo "Processing $Uri"
    echo "Reading storage account information..."
    $acct = Get-AzureStorageAccount | ? { (new-object System.Uri($_.Endpoints[0])).Host -eq (new-object System.Uri($Uri)).Host }
    if(-not $acct) {
    write-host "The supplied URL does not appear to correspond to a storage account associated with the current subscription." -foregroundcolor "red"
    break
    $acctKey = Get-AzureStorageKey ($acct.StorageAccountName)
    $creds = "DefaultEndpointsProtocol=http;AccountName=$($acctKey.StorageAccountName);AccountKey=$($acctKey.Primary)"
    $acctobj = [Microsoft.WindowsAzure.Storage.CloudStorageAccount]::Parse($creds)
    $uri = $acctobj.Credentials.TransformUri($uri)
    echo "Confirmed - storage account '$($acct.StorageAccountName)'."
    $blob = New-Object Microsoft.WindowsAzure.Storage.Blob.CloudPageBlob($uri, $creds)
    echo "Checking whether the blob is currently registered as a disk or image..."
    $disk = Get-AzureDisk | ? { (new-object System.Uri($_.MediaLink)) -eq $blob.Uri }
    if($disk) {
    write-host "The blob is still registered as a disk with name '$($disk.DiskName)'. Please delete the disk first." -foregroundcolor "red"
    break
    $image = Get-AzureVMImage | ? { $_.MediaLink -eq $blob.Uri.AbsoluteUri }
    if($image) {
    write-host "The blob is still registered as an OS image with name '$($image.ImageName)'. Please delete the OS image first." -foregroundcolor "red"
    break
    echo "Confirmed - the blob is not in use by the Windows Azure platform."
    echo "Inspecting the blob's lease status..."
    try {
    $blob.FetchAttributes()
    } catch [System.Management.Automation.MethodInvocationException] {
    write-host $_.Exception.InnerException.Message -foregroundcolor "red"
    break
    echo "Current lease status: $($blob.Properties.LeaseStatus)"
    if($blob.Properties.LeaseStatus -ne [Microsoft.WindowsAzure.Storage.StorageClient.LeaseStatus]::Locked) {
    write-host "Success - the blob is unlocked." -foregroundcolor "green"
    break
    echo "Unlocking the blob..."
    $request = [Microsoft.WindowsAzure.Storage.StorageClient.Protocol.BlobRequest]::Lease($uri, 0, [Microsoft.WindowsAzure.Storage.StorageClient.Protocol.LeaseAction]::Break, $null)
    $request.Timeout = $blobclient.Timeout.TotalMilliseconds
    $acctobj.Credentials.SignRequest($request)
    try {
    $response = $request.GetResponse()
    $response.Close()
    catch {
    write-host "The blob could not be unlocked:" -foregroundcolor "red"
    write-host $_.Exception.InnerException.Message -foregroundcolor "red"
    break
    $blob.FetchAttributes()
    echo "Current lease status: $($blob.Properties.LeaseStatus)"
    write-host "Success - the blob is unlocked." -foregroundcolor "green"

Maybe you are looking for