Current Fiscal Year
Hi,
Is there an oracle function that returns the current fiscal year in format (2012/2013)?
Thanks
Hi,
sliderrules wrote:
Is there an oracle function that returns the current fiscal year in format (2012/2013)?That depends on what you mean by fiscal year.
If a fiscal year begins on April 1 of every calendar year, then
ADD_MONTHS ( TRUNC ( ADD_MONTHS (d, -3)
, 'YEAR'
, 3
)is the beginning of the fiscal year that contains DATE d. The "magic number" 3 reflects the fact that the fiscal year starts 3 months after the calendar year.
If you want a string like '2012/2013' that shows the calendar years when the fiscal year begins/ends, then use the expression above to get the beginning date, use EXTRACT to get the year as a number, and then add 1 to it.
If you're just interested in the year number, as in your message, then you don't need the outer ADD_MONTHS or TRUNC; you can just EXTRACT the year from <tt>ADD_MONTHS (d, -3)</tt>
You might consider a user-defined function for this. It will be slower than doing it in pure SQL, but it will be a lot more convenient. You don't have to use the function in situations where performance is an issue.
I hope this answers your question.
If not, post a little sample data (CREATE TABLE and INSERT statements, relevant columns only) for all tables involved, and also post the results you want from that data.
Explain, using specific examples, how you get those results from that data.
Always say which version of Oracle you're using (e.g., 11.2.0.2.0).
See the forum FAQ {message:id=9360002}
Edited by: Frank Kulash on Mar 14, 2013 11:30 AM
Similar Messages
-
Reversal of Last Fiscal year asset in current fiscal year
Dear SAP experts
Asset has been booked in last fiscal year (jan2006) depreciation also posted till this fiscal year last month (2007 June)
Asset value-70000 (invoice value)
Accumulated Depreciation-33753.42
Asset net book value as on date- 36246.58
With same information one more asset also booked by mistake, so my client want to reverse any one of them asset with depreciation (which has booked in last fiscal year)
I tried with asset credit memo (T code ABGF); it is picking up only asset net book value (36246.58) not accumulated depreciation (which is already affected in Accumulated GL account).
Can you tell me is there any way to solve this problemHi Chaitanya,
If you have already acquired and depriciated the asset in previous fiscal year and closed the books and published the results why do you want to reverse it now. from accounting point of view also how would you show the entry for reversal of depriciation.
Any how the acqusition and depriciation posted in previous fiscal year can not be reversed in current fiscal year it can be reversed only in previous fiscal year. as per SAP standards you can write up the asset if you have wrongly depricaiated the asset.
Or else you can retire the asset with revenue which will give the same financial impact as you are expecting.
Thanks & Regards
Sree -
I would like to display current fiscal year always on variable screen
Hi
I have requirement in which I would like to display the current fiscal year on variable screen in BI Report.
we have a standard variable however the sap exit to display the current fiscal year is not shown...
Can any one tell me, how to proceed in this case.
Thanks
ChetanHello,
For I-step = 1, use the function module DATE_TO_PERIOD_CONVERT.
here for IMPORT use i_date = sy-datum and i_periv = ur fiscal variant.
The output is e_buper contains fiscal period and e_gjhar contains fiscal year.
The use concatenate to join fiscal year and fiscal period to the variable low value.
Regards,
Shashank -
Asset write off in the current fiscal year.
Hi Experts,
I want to write off an asset in next 4 periods of the current fiscal year 2007. For example:
Asset 11000
APC value: 10000
APC Date: 01.01.2005
The useful life will end in fiscal year 2008.
The book value left at the begining of the current fiscal year 2007 Rs. 4000.00
In the current fiscal year this asset has already been depreciated for previuos 3 periods.
Now Business wants to write off ( fully depreciated ) this asset in next 4 periods equally and then if the book value and tax value is nil, they want to scap the asset.
Now can you please tell me how to make this happened. Its very urgent. If you need any more information, most welcome.
Rgds,
BABAHi,
You would have to set the asset to manual depreciation(Depr.Key MANU)
and generate a posting via ABMA for each of the periods.
Kind regards -
Function module to read customer balances for current fiscal year.
Hi,
Could anyone please tell me about the function module which would display the customer credit balances from the FD10n transaction code for teh current fiscal year. that means from july 2010 to july 2011.Hi,
use the BAPI 'BAPI_AR_ACC_GETCURRENTBALANCE'
CALL FUNCTION 'BAPI_AR_ACC_GETCURRENTBALANCE' "Closing balance of customer account in current fiscal year
EXPORTING
companycode = " bapi3007_1-comp_code Company code
customer = " bapi3007_1-customer Customer
IMPORTING
actual_balance = " bapi3007_9 Carry forward balance and balance
return = " bapireturn Return Code
. " BAPI_AR_ACC_GETCURRENTBALANCE
This method provides a customer's balance for the current fiscal year.
It displays both the balance of standard transactions and the total balance of standard transactions and all special general ledger transactions.
Read the Documentation of the BAPI.
Regards,
Dhina.. -
To post write up in the current fiscal year
Hi,
I am trying to post write up in the current fiscal. However, the system is not allowed to post me. I know that the write-up needs to be posted from the next fiscal year. However, due to the requirement, we need to post in this current and switch off the message. I have already switched off the message in OBA5, but still, I cannot proceed to post with write-up in the current year. Is there a way that I can post this.
The following are the error details.
You cannot post write-ups
Message no. AA400
Diagnosis
According to the transaction type, you have to post to area 01. However, in this area, there is either no accumulated depreciation or the write-up depreciation type(s) are not managed in this area.
Procedure
Check the transaction type.
Regards,
RaviHi Ravi,
A write up can only be carried out if you have cumulated depreciation values (from previous years). In the current fiscal year depreciation should be posted the 'normal' way. Write ups mean that too much depreciation was posted in a previous year and that you will correct this in the current year. Therefore, the system does not allow posting write ups if there exist no cumulative depreciation values from previous year. In other words you cannot perform a write up for an asset in the year of acquisition.
Also make sure that the depreciation area(s) is defined as such to manage cumulative depreciation type or write-up depreciation type. This should eliminate the error 'AA400'.
Following is the menu path to take:
CU: FI-AA
-> Transactions
- > Define Transaction Types for
- > post-capitalization (trans. AO77 and OAXD)
-> manual depreciation (trans. AO78 and OAXE)
For both,- select your Chart of Depr.
- >select your Transaction Type
-> select Depr. Area Specs.
Regards Bernhard
Edited by: Bernhard Kirchner on May 10, 2010 3:00 PM -
Variable to display data from Current Fiscal Year to the MONTH entered
Hi Friends,
In the Quey Designer I require a CHARACTERISTIC VARIABLE for the 0CALMONTH which should have the following features:-
1.Input Month(e.g JUN 2008)
2.Mandatory
3.Ready for Input
The query should show the following OUTPUT:-
The data should be displayed from the CURRENT FISCAL YEAR to the value of the Input MONTH entered.
e.g For Input = DEC2008
Output = from APRIL 2008 to DEC2008.
Do we have a standard variable for this or we have to go for a Customer Exit??
Thanks in Advance!!!
VivekHi,
Create a customer exit as follows.
WHEN 'ZCMTD'.
you variable name
data: ZCMTD_LOW like sy-datum.
ZCMTD_LOW = sy-datum.
ZCMTD_LOW+4(2) = '04'.
*replacing last two symbols (month) in the current month with '04'
CLEAR L_S_RANGE.
L_S_RANGE-LOW = ZCMTD_LOW.
*initializing low interval limit
L_S_RANGE-HIGH = SY-DATUM.
*initializing high interval limit
L_S_RANGE-SIGN = 'I'.
*defining interval as inclusive
L_S_RANGE-OPT = 'BT'.
APPEND L_S_RANGE TO E_T_RANGE.
ENDCASE.
Thanks,
Ashok -
How to design extractor can have only current Fiscal Year data.
Dear Experts,
I require a full upload DSO , which can have only current fiscal year data . I have created view putting there certain conditions for minimising the data size. How i can restrict it , to have only current fisacal year data for YTD reports. It would be daily uploaded.
Should i created Data Source based on function ?
Regards,
Anand Mehrotra.while extracting the data from source you can set the filters at the info package level so that it will not extract the previous years data.
In the data selection tab in Info package enter the current fiscal year and schedule the IP it will extract only the current year data.
next execute the DTP to load data till DSO.
the data is restricted in the infopackage level before entering to PSA so there is no need to write any routines in the DSO level.
Edited by: prashanthk on Feb 1, 2011 12:45 PM -
How to get last 35th fiscal year periof form current fiscal year period
Hi,
I want last 35th moths fiscal yesr periof from current fiscal yesr periog.
E.g. current month FISPER - 2010011 so required FISPER is 2010011 - 35 = 2007009.
Please help if any one know about it.
Marks will be provided.Hi,
Drag Fiscal year/period characteristic in the query and restrict it .
In the variables , you will find SAP delivered variable which willl give you current fiscal year/period.
Create range on the using this variable and give offset of -35.
For eg.
the name of the variable is 0PF_CP, then create range in the following way.
Lower range will be 0PF_CP - 35
and higher limit will be 0PF_CP.
So the range would be 0PF_CP-35 : 0PF_CP.
This will give you the last 35 fiscal year/period.
- Jaimin -
Year To Date for Current Fiscal Year
Hi All,
I have installed BC variable Year To Date for Current Fiscal Year 0I_CFYTD..
foloowing error occurs
Variable 0I_CFYTD could not be replaced..
Do i need to write any code or Please help.....Hi,
Please check if fiscal year variant is used in the filter. Else the BC variable throws an error. Drag fiscal year variant to the filter area and set a value or variable input for the same.
Regards,
Satya -
How to get current fiscal year.
Hi Experts,
I am working on Asset Management.I need to get current fiscal year.
I have to enter fiscal year on selections screen which i have to validate that it should not be greater than current fiscal year.
For above i have used following code snippet but i have hard coded variant as 'MK'.
To get variant i was using function '/IBS/RB_FI_GET_FISCAL_YEAR_VAR' but in my selection screen we have to enter multiple company codes. if i will keep this function inside loop then it may give multiple variants.
How to resolve this ?
DATA : l_year(4) type c,
l_date TYPE sy-datum.
CALL FUNCTION '/IBS/RB_FI_GET_FISCAL_YEAR_VAR'
EXPORTING
i_company_code =
IMPORTING
E_FISCAL_YEAR_VARIANT =
EXCEPTIONS
COMPANY_CODE_NOT_FOUND = 1
OTHERS = 2.
l_date = sy-datum - 700.
l_date = l_date + 1.
IF sy-subrc EQ 0.
CALL FUNCTION 'GM_GET_FISCAL_YEAR'
EXPORTING
I_DATE = l_date
i_fyv = 'MK'
IMPORTING
E_FY = l_year
EXCEPTIONS
FISCAL_YEAR_DOES_NOT_EXIST = 1
NOT_DEFINED_FOR_DATE = 2
OTHERS = 3.
IF sy-subrc EQ 0.
IF s_gjahr-low GT l_year.
PRINT Error Message "Entered fiscal year should not be greater than current fiscal year".
ENDIF.
ENDIF.make it simpler by using - DATE_TO_PERIOD_CONVERT
CALL FUNCTION 'DATE_TO_PERIOD_CONVERT'
EXPORTING
I_DATE = SY-DATUM
I_PERIV = L_VARI "Fiscal year Variant - refer to tab T009B
IMPORTING
E_BUPER = L_BUPER " Fiscal Period
E_GJAHR = L_GJAHR " Fiscal year
EXCEPTIONS
INPUT_FALSE = 1
T009_NOTFOUND = 2
T009B_NOTFOUND = 3
OTHERS = 4
Hope this will solve ur problem. -
System fiscal year in co code does not match current fiscal year.
Hi
I have seen this problem.I did run some closing steps and this error gone . Can some one please explain some logic behind this error ? Because I am sure i have not done any specific transaction to match the system fiscal year and current fiscal year then how this error gone away ?
I have checked the other posts on this forum related to this error but still feel to ask for clarity of concept.
Thanks in advance
SatyaHi Satya,
Ex:
FY is 2011 ( for US)
compny code FY may / may not same as system FY.
for Business adjust ment / Financial Adjustments client not close previous FY.
now if you check your system, Comp Code FY is 2010 & System FY is 2011.
Company Code Closing FY T.Code: OAAQ
Tables need to chek for conformation year end activities done/not: TABA, T093B, T093C
Regards,
Viswa -
Var. Exit code for Fiscper of Current Fiscal Year
Hi Guys,
I need to create a variable exit to calculate the Current Fiscal Period of Current Fiscal Year. (STrange requirement)
Can anyone please help me with the sample code?
RegardsYou can use DATE_TO_PERIOD_CONVERT based on the current date (sy-datum).
call function 'DATE_TO_PERIOD_CONVERT'
exporting
i_date = sy-datum
i_periv = w_fiscal_year_var
importing
e_buper = w_period
e_gjahr = w_year
exceptions
input_false = 1
t009_notfound = 2
t009b_notfound = 3
others = 4. -
ALV Report to check upto current fiscal year
Hi All,
I am running a reoprt. its output is in this way.
Division Fiscal year Net Price.
Chemical 2006 3456456
2007 5456436
2008 45345
2009 4545
2010 45456
Over Due
Due
0 to 30 days
and so on
Now My problem here is I have this secctionof cede it should increase my fiscal year, But I checked it in the run time its not stopping at the S-fkdat-high, ( I mean in the current fiscal year.). Here also I am posting the section of code.
Can any body identitfy where my code is wrong, and why its not stopping at the currennt fiscall year.
S_FKDAT = S_FKDAT-LOW+0(04).
APPEND S_FKDAT.
DO.
IF NOT S_FKDAT IS INITIAL.
S_FKDAT = S_FKDAT + 1.
APPEND S_FKDAT.
CHECK
S_FKDAT = S_FKDAT-HIGH+0(04).
STOP.
APPEND S_FKDAT.
ENDIF.
ENDDO.
Thanks in Advance
Edited by: Ravi Narayan Padhi on Oct 14, 2010 3:09 PMHI,
iam not getting wat ur try to do here in this logic can u elaborate the logic
As per my understanding ur requirement logic should be -->
if not S_FKDAT[] IS INITIAL.
read table S_FKDAT index 1.
while S_FKDAT-low ne sy-datum+0(4).
S_FKDAT-option = 'I'
S_FKDAT-sign = 'EQ'
S_FKDAT-low = S_FKDAT-low + 1
APPEND S_FKDAT.
endwhile.
endif.
Regards,
Madhukar Shetty -
What varaible is best to use for current fiscal year.
Hello all,
I have few restricted key figures which need to be reported as "for current fiscal year" so which ios the best variable we can use for that.In the filter area I have fiscal year variant and comp code do I have to give users the input ready for fiscal year?
Also then i need comparison between current and previous year for same RKF so I plan to offset the varaible by "-1" .
ThanksIt works for me Bhanu. Last I used that it gave me errors so was not sure.
for YTD i dont see any variable in fiscal year am I looking at wrong place.
can you suggest something
Thanks
Maybe you are looking for
-
Hey all, So, I was working on a project on a faster computer, and then moved it to my laptop. I tried to open it on my laptop (same version, Premiere Pro CS4 4.2.1), and whenever I try, it crashes and opens the crash report. When I try to create a ne
-
Sudden increase in disk space?
I've been working with 20 GB or so available on my startup disk for around 6 months now. A couple of days ago I got the Startup Disk almost full message. I saved my work and rebooted. That solved the problem and I gained 3-4 GB. Yesterday morning sud
-
Impact of invoice reversal to accounting
good day experts!! what impact does invoice cancellation/correction have on accounting department wen they hav already cleared the invoice? can the invoice repeatedly be paid to contractors becauase of invoice reversal? these is in terms wen trying t
-
Sap CRM Interactive Reporting Managers only see their own Opportunitys
Hi Sap Community, I have set up Interactive Reporting as described in the C41 guide, "/CRMBW/CONFIG_WIZARD" shows no Errors and it works fine for normal employees but when I execute a report as a manager, i can only see Opportunitys, where the manage
-
I downloaded Firefox 4 on another laptop without issue (it has windows 7). I downloaded it again on another computer (a lil older with Windows Vista) and it wouldn't open from the very beginning. I fixed the firewall as stated in the help section. I