Defining an exit variable for a specific day based on Fiscal Period
If I do not have Calendar Day time dimension available for reporting is it possible to define a customer exit variable for a specific day. The days are the first and last day of the financial year?
Example
User Input for Fiscal Period: 2009004
The exit is to define a value for 01.01.2009 and 31.12.2008 (end of last year)
Thanks
Hello Niten,
yes it is possible. Procedure:
- add a new column in the report structure
- hide this column
- create a new text variable in this column (for customer exit)
- now you can fill this variable during query execution based on 0FISCPER
You don't want to filter by this variable. Right?
Buy,
André
Similar Messages
-
Customer exit Variable for Previous 12months Rolling based on 0calday
Hi Experts,
I am creating a Customer exit variable to derive Rolling 12 months based on calday,
Could you please any body correct the below code,
Or if you any body have pseudo code based on calday, could you please pass to me
WHEN 'zcalday'.
* Rolling 12 months to period
IF i_step = 2.
CLEAR: l_s_range, loc_var_range,
LOOP AT i_t_var_range INTO loc_var_range
WHERE vnam = 'RYEAR'.
MOVE sy-datum TO: lv_date_from,
lv_date_to.
zmonth = lv_date_from+4(2)
l_s_range-high = zmonth = loc_var_range-low.
v_fiscper = v_fiscper - 12.
l_s_range-low = v_fiscper.
l_s_range-sign = 'I'.
l_s_range-opt = 'BT'.
APPEND l_s_range TO e_t_range.
ENDLOOP.
ENDIF.
Thanks and regards
SreeHi Yasemin,
Thanks for your help,
I have small clarification, I have following data in base cube,After restricting the customer exit variable
on revenue I suppose I will get one Amount, i.e 7800, But If I want month wise, Do I need to create offset? or without creation of offset is there any way that will split based customer exit variable.....
Thanks a lot
regards
Sree
Execution date
24/06/2014
Comp Code
Date
Revenue
C100
01/07/2013
100
C100
01/08/2013
200
C100
01/09/2013
300
C100
01/10/2013
400
C100
01/11/2013
500
C100
01/12/2013
600
C100
01/01/2014
700
C100
01/02/2014
800
C100
01/03/2014
900
C100
01/04/2014
1000
C100
01/05/2014
1100
C100
01/06/2014
1200
Total
7800 -
Hi Gurus,
I have installed the standard Business Content for Personnel Administration in BW. I have to calculate Headocunt for a specific day ( "As of day") in a query. How do I get about doing this. Any help is deeply appreciated.
ThanksHello John,
I assume that user will entry the key date as on which the count has to be shown. This date variable cannot be based on a characteristic. It has to be a formula variable of date type, ready for input.
Now, Create 2 more formula variables replacement path type for start date and end date.(we need these in calculation)
Now create a formula(local CKF) and write:
(key_date > stat_date && key_date < end_date )* count
This will show the count of employees who joined after start date and who have not left till the key date entered by user.
Count is the count of unique employee ids. It can be made as a formula in front end or a counter at the back end.
Best Wishes,
Mayank -
How do i filter a search to find all photos for a specific day and month for all years?
Hmm.. Well, the only way I've been able to see that is to use filters, and control click on each year-day combo (using control/command click to select more than one entry) and LR will show them all. You might then drag them into a collection...
Of if you're not doing this a lot, you could create a smart collection and make a field for each year by "capture date" (which apparently won't let you add wildcard values).
If nobody else has a better suggestion (quite possibly they will!), then you might put in a feature request to allow Date in smart collections to have a wild card.
Cheers! -
How to get 2 Dates of a specific day From a Pay period
Hi
I have a date range (Pay period). now from the start date i Need to find out both Dates of a specific day of that Pay period.
For Example If i know the date range is
01/06/2007 to 01/19/2007
Then I need to know what are the dates for both Saturdays.
Here it should be 01.06.2007 and 01.13.2007.
Please help. I always award points. Thanks
Message was edited by:
Anwarul KabirHi,
Please try this.
PARAMETERS: P_START LIKE SY-DATUM,
P_END LIKE SY-DATUM.
DATA: DAYS TYPE I,
WEEKDAY LIKE DTRESR-WEEKDAY.
DAYS = P_END - P_START.
DO DAYS TIMES.
CALL FUNCTION 'DATE_TO_DAY'
EXPORTING
DATE = P_START
IMPORTING
WEEKDAY = WEEKDAY.
IF WEEKDAY = 'Sat.'.
WRITE: / P_START.
ENDIF.
P_START = P_START + 1.
ENDDO.
Regards,
Ferry Lianto -
Macro to Unlock the Cell on the start day of the Fiscal period
Dear Experts
We are using fiscal periods for the forecasting.1 period = 15 days.We forecast for 24 fiscal periods.
We only give chance to some customers to update forecast on 1 day of the fiscal period in the customer planning book .In this regard we have to lock the cell all most all the days except on 1 st day of the fiscal period.If the first of the Fiscal period is Sunday or Saturday, system should not unlock.
We did not maintained any Time stream ID to the storage bucket profile.
Example:
KF1 is used by our customers to update forecast.This keyfigure should always in the unedit mode.On the first day of the Fiscal period system should unlock the keyfigure.If first day of the period is saturday or sunday then system should not unlock this keyfigure.
Can we use calender in Macro?
Is it possible to achieve above logic in our case since we did not maintained time stream ID in storage bucket profile.
Please give your expertise opinion on my requirment.
regards
VickyHi Vicky,
Whilst other simpler options are given by others for locking /unlocking a KF with macros, Work around as below, if feasible in your environment.
Create two planning books (or with authorization at data view level, 2 data views).
One planning book PB1 with the KF1 in non-edit mode. This will be used normally.
Other planning book PB2 with KF1 in edit mode.
Create one more authorization profile/ role for each customer user.
Assign this additional authorization profile/ role only on specific dates as per background job to give additional authorizations.
Otherwise, if no. of user licenses is not an issue, then create an additional user id for each of the customer with additional authorizations and unlock these additional user accounts only on specific dates by background jobs.
We had in one project, some additional user accounts for similar( not exactly same) requirement. This gave better traceability.
Regards
Datta -
How to get total number of days in current Fiscal period/year
Hi,
I need to get total number of days in current Fiscal period/year (current month) and assign it to an infoobject. I need a routine for this. Is there any function module to get this.If possible pls paste the ABAP code also for this task. Thanks in advancehere is the FM:
LAST_DAY_IN_PERIOD_GET
KJ!!! -
User Exit Variable for Calculating number of days in a month
I need a query to calulate the number of days in a particular month upto the current date. For example if i give 26 Feb it should reutrn 25, if i enter 30march it should return 29 for any specific year. I have gone through some posts and understood that i need to create a formula variable (under calculated KF's) and then go to CMOD, create a project, then enancement Assignment RSAP0001 then EXIT_SAPLRSAP_001 and include a code in INCLUDE ZXRSAU01. But i have any clue of coding. Could someone give me the entire code and how to connect it to the formula variable KF in created. The technical name of the key figure is ZMDAYS. If i have made any mistakes or if there is another eaier alternative please let me know. I thankyou all for the help.
Hi Uday,
I have a few modifications in the code
Data: xdate type d,
ip_year(4) type N,
ip_month(2) type N.
Types : Begin of ty_month_days,
month(2) type N,
days(2) type N,
End of ty_month_days.
Data : it_month_days type ty_month_days occurs 0 with header line.
ip_year = 2006.
ip_month = 01.
do 12 times.
CONCATENATE ip_year ip_month '01' INTO xdate.
xdate = xdate + 33. "this date is in the next month
xdate+6(2) = '01'. "first day of next month
xdate = xdate - 1. "last day of xmonth
it_month_days-month = xdate+4(2). "number of days of xmonth.
it_month_days-days = xdate+6(2).
append it_month_days.
ip_month = ip_month + 1.
enddo.
This code stores Month and No. of days in the internal table it_month_days.
You can access this internal table for your calculations
This should help.
Regards,
Praveen.
Message was edited by: praveen mathew -
Portal: how to define new text variables for information broadcasting
Hello everybody,
I hope the post here is placed on the right position. If not, please try to advise me, where to ask to get answer on following question:
-> In BI Portal -> tab Business Intelligence -> Bex Broadcaster -> it is possible to create PDF and post it somewhere into Portal or any other network drive. That's fact. I'm searching for possible enhancement of the F4 help next to the field "data name". There are available only following few variables <OBJECT_ID> <SETTING_ID> <OWNER_ID> <PROCESSED_BY_ID> <LANGUAGE_ID> <DATE_ID> <TIME_ID> <WEEK_ID> <MONTH_ID> <QUARTER_ID> <YEAR_ID>
We are facing this issue: generated analysis file is valid for the period from month 01 to month actual-1. So therefore I would like to implement my own variable.
Do you know guys, where to define this own variable with own logic?
Could you please give me some hints how to create a new one and fill the logic?
Thank you very much in advance
StanNot resolved. Life goes still on.
-
User Exit Variable for Bex in CMOD (ABAP Code)
Hi Experts
My requirment is to develop a Restricted Keyfigure...
The restriction is based on 0Calmonth (Calendar Year/Month)
The sales from beginning of calendar year up to last "closed" month in a Calendar.
Ex: in June i want to see 01.01.2009 to 31.05.2009 data.
in October i want to see 01.01.2009 to 30.09.2009 data.
When user execute the report
in Jan 2010 i want to see 0 as there is no closed month in that particular year.
in Fed 2010 i want to see 01.01.2010 to 31.01.2010 data.
For that purpose i need to create a User Exit variable in CMOD...
I am struggling to get an idea on how to write a code to meet the requirment
Please help me with code that i can use in cmod
Thanks in advanceHi,
Use the following code :
when' variable name ' .
DATA : year(4) type n,
month2(2) type n,
date_in type sy-datum,
date_op type sy-datum.
IF I_STEP = 1.
CLEAR L_S_RANGE.
L_S_RANGE-SIGN = 'I'.
L_S_RANGE-OPT = 'BT'.
month2 = sy-datum+4(2).
if month2 = '01'.
concatenate sy-datum+0(4) '01' '01' into l_s_range-low.
l_s_range-high = sy-datum.
else.
month2 = month2 - 1.
clear : date_in, date_op.
concatenate sy-datum+0(4) month2 '01' into date_in.
CALL FUNCTION 'SLS_MISC_GET_LAST_DAY_OF_MONTH'
EXPORTING
DAY_IN = date_in
IMPORTING
LAST_DAY_OF_MONTH = date_op
EXCEPTIONS
DAY_IN_NOT_VALID = 1
OTHERS = 2
IF SY-SUBRC <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
concatenate sy-datum+0(4) '01' '01' into l_s_range-low.
l_s_range-high = date_op.
endif.
APPEND L_S_RANGE TO E_T_RANGE.
ENDIF.
I dint know what output do you want if the current month is jan.
I have put it as 1st jan till current date.
Modify it if you need.
Regards,
Mansi -
Error when using SAP Exit Variable for Current Fiscal Period (0FPER)
Hi Friendz,
My requirement is to execute a query for the current fiscal period. I am using the SAP Exit Variable 0FPER.
I placed this variable on char. Fiscal year/period 0FISCPER.
When I execute the Query, it is returning the error: No value could be determined for variable ZVBSYCUR; Variables Contain Invalid Values.
Please give inputs on how to use this variable.
Regards...
GaneshHello Dipika,
I am also getting the same error.
ERROR: Variable 0FPER could not be replaced.
Yesterday we created one customer exit. But this should not affect the SAP Exit right? Till yesterday the 0FPER variable was working fine. I tried re-installing from BI content, but still getting the same error. If anybody has a clue please let me know.
Thanks,
Harshal -
Custom exit variable for fiscal year/period
Hi BI Experts
1) In one of the column i just want Budget data to be displayed for the entire year..i.e even if the user enters 005/2006 for fiscal year /period that column should display 001/2006 to 012/2006 Budget.
I have created a restricted KF for 0AMOUNT restricted by version(for Budget), valuetype (for Budget )
now how do I assign variable for Fiscal year/period...and the problem is posting period is not populated ...I mean there is no transformation for that...
Can you share your experience on that ...full points wil be awarded...
ThanksHi Ajay and Pradhiba
I am really sorry for assigning you guuys points ...wasa bit busy ...
The problem is that the year and posting period is not populated...there fore I cannot use those time characteristics...
Now I have only fiscal year/period populated..now i want
if the user enters 005/2006 ....i want my first column to calculate the data for 001/2006 to 012/2006 ...thats the req...
can u share ur ABAP experience in that...
thanks -
User Exit Variable for Infoprovider based on month characterstic in query
Hi,
I am financial reporting with reports created on a mulit-provider over a plan & Actual cube. Along the top of the report is a structure which has amongst other restricitions a column for each month, i.e columns 1 to 12.
Currently we are in month 9, so the report should show data from the Actual infoprovider for months 1 to 9, but data from the plan infoproviders for 10 to 12. My question is how should the variable be coded for the infoprovider which will return a value based on the month characteristic in each columns selection. I understand how I can look at say the current system date, derive the month and return the plan/actual value for the correct infoprovider based on the current month. But I need to create a variable which will look at the month value which is in each column selection in the query itself.
Many thanks,
Richardwe recently had this kind of reporting requirement. only difference being week instead of month.
you need to create 12 variables for actual month columns and 12 for budget.
now you will write a code to address all the variables. in following format :-
when var1. "suppose var1 represents month 1 of actual columns
1. derive month from date.
2. if month <= i_vnam+3(1) "get the number from var and compare
set the variable value as the month number of that year for e.g
concatenate year i_vnam+3(1) into l_s_range-low
else
set the variable value way back in past which will not have any data.
above logic will cause values in following fashion
if this month is 3 and year is 2008
var1 = 200801
var2 = 200802
var3 = 200803
var4 = 199001
var5 = 199001
etc.
In the query all columns will be set with the property = hide if not values are present. so if 199001 is set in the variable then it will be collapsed.
same way logic for variables in budget column can be written which will set all the month variables which are less than
current month to 199001 (just in reverse fashion of above mentioned logic.) -
Creation Exit variable for Sales office Characteristic
Hi Experts, can anybody suggest me,
My requirement is like i have to create Exit Variable on Sales Office Characteristic, by using Exit, in this exit it i should get the values of Sales office 2201 To 2299 only.
plese give the sample code tobe written in the Function Module.
Thanks in Advance.Hi,
You can check with code below in function module:-
Parameters of function module:
Import : I_area type UPC_Y_Area.
ITO_CHA type UPC_YTO_CHA.
Changing : XS_CHA type any.
Source code
Field symbol: <salesoffice> type any.
assign component of 'Technical name of sales office ' of structure xs_cha to <salesoffice>.
If <salesoffice> <= 2201 and <salesoffice> >= 2299.
Message e001(message class).
endif.
Hope it may be helpful. -
Customer exit to get the result in between two fiscal periods
Hi Guys,
I have a requirement to write customer exit, in which i have to get the result for a range of fiscal periods,
that is in Between fiscal period1 and fiscal period3,
and i am getting this Fiscal period from other variable called version in which it consists of combination of fiscalperiod and text
and now i have filtered the fiscal period and stored in Final_val ( this is an interger), but how can i use dynamically this Final_val to get the results in between Final_val1 and Final_val3 ( that means if the Final_val is 2008010 then i have to get the results in between 2008011 and 2009001).
Please provide me the solution, with the possible piece of codeHi Diogo,
Here is the code
WHEN 'ZC_PVR'.
DATA: FIN_YEAR(4) TYPE C,
FIN_DATE(3) TYPE C,
FIN_VAL(7) TYPE C.
IF I_STEP = 2.
READ TABLE I_T_VAR_RANGE INTO LT_VAR_RANGE WITH KEY VNAM = 'ZC_VCS'.
IF SY-SUBRC EQ 0.
CONCATENATE '20' LT_VAR_RANGE-LOW+2(2) INTO FIN_YEAR.
CONCATENATE '0' LT_VAR_RANGE-LOW+4(2) INTO FIN_DATE.
CONCATENATE FIN_YEAR FIN_DATE INTO FIN_VAL.
CLEAR L_S_RANGE.
L_S_RANGE-LOW = FIN_VAL.
L_S_RANGE-HIGH = ''.
L_S_RANGE-SIGN = 'I'.
L_S_RANGE-OPT = 'BT'.
APPEND L_S_RANGE TO E_T_RANGE.
ENDIF.
ENDIF.
which i am using for Filter the fiscal period, after this when i tried to restrict on this "ZC_PVR" vairable and set the offset like
zc_pvr 1 to zc-pvr3 under value of ranges, but i am facing an error saying the " variable may be deleted or used incorreclty",
could u plz suggest
Maybe you are looking for
-
How do I access icloud keychain?
I know the password was kept in the icloud keychain? On my Mac I start up the utility keychain. Put in enough letters too narrow the search, pick the correct password/user name. Authorise viewing the password in plain text. And read the result. How d
-
Pictures are not coming up on the internet
'''when I open the internet, the pictures do not appear. When I go into some sites that I use frequently, the graphics for the buttons do not appear. '''
-
i bouhght my Macbook pro retina display 13 Inch i5 a week ago and I spilled a liquid on my keyboard , and i would like to know how much coast to repair the damage in apple store , i didnt buy in the offical apple shop. Some places are asking to pay
-
HI! My itunes on windows 7 opens once. If i close it, then it will not open again. I then need to turn computer off and back on and it will open again, once. I have tried troubleshooting with the article 'unexpected quits, freezes or launch problems'
-
Mail doesn´t open with in-box
Hello ! Since 2 weeks or so mail opened with a folder "october12" and not with the in-box. I try to "highlight" in-box, close mail and open it again, but still the same. What can I do to make mail open with the in-box ? Thanks in advance !