To get Current,Last, Next months data for Efashion report
To Create a report with the user input prompt on Year and Month:
If user select year as 2005 and month as 2 (Feb), revenue should be displayed for previous Month (Jan) and next month (March) of selected year.
Sample output should looks as below.
Year : 2005
State
Prev Month - Jan
Current Month - Feb
Next Month - Mar
AAA
$100
$100
$600
BBB
$200
$400
$200
CCC
$300
$300
$300
I have created dimensions in universe premonth=(@Select(Time period\Month) -1) & Nextmonth=@Select(Time period\Month) +1) & taken 3 dataproviders from efashion universe .these are not working for year ends
Hi
solution found, taken 3 data providers & added below filters for 2 &3 data providers
DP2
@Select(Time period\Year)=iif(@Prompt('Enter Month','N','Time period\Month',,)=12,@Prompt('Enter Year','A','Time period\Year',,)+1,@Prompt('Enter Year','A','Time period\Year',,))
@Select(Time period\Month)=iif(@Prompt('Enter Month','N','Time period\Month',,)=12,1,@Prompt('Enter Month','N','Time period\Month',,)+1)
DP3
@Select(Time period\Year)=iif(@Prompt('Enter Month','N','Time period\Month',,)=1,@Prompt('Enter Year','A','Time period\Year',,)-1,@Prompt('Enter Year','A','Time period\Year',,))
@Select(Time period\Month)=iif(@Prompt('Enter Month','N','Time period\Month',,)=1,12,@Prompt('Enter Month','N','Time period\Month',,)-1)
Thanks
Similar Messages
-
Getting the last succesful logoin date for user
Hi ,
Iwant to write an java application which will take the userid and get the
last sucessful login date.
I used the sap ume apis for this purpose
There is an API getLastSuccessfulLogonDate() in the class IUserAccount.
But it says
Deprecated.
get last sucessful logon date NOTE: This attribute is not automatically updated during login.
link :https://help.sap.com/javadocs/NW04/current/um/index.html
What does "attribute not updated automaticlaly during login implies".
Is there any other method from where i can get this information
Regards
ManojFew things to mention.
I am using SAP Netweaver 2004s
When i run the code
thisUser = userFact.getUser(userid);
IUserAccount userAccts[] = thisUser.getUserAccounts();
System.err.println(" Iterating in for loop ");
for(int i=0; i<userAccts.length; i++)
d= userAccts<i>.getLastSuccessfulLogonDate();
System.err.println(" got date ");
result = d.toGMTString();
I get the following exception
Login date java.lang.NullPointerException
at SecurityLogic.getLastSuccessfulLogonDate(Unknown Source)
at SecurityRemoteObjectImpl0.getLastSuccessfulLogonDate(SecurityRemoteOb
jectImpl0.java:125)
at SecurityRemoteObjectImpl0p4_Skel.dispatch(SecurityRemoteObjectImpl0p4
_Skel.java:186)
at com.sap.engine.services.rmi_p4.DispatchImpl._runInternal(DispatchImpl
.java:304)
at com.sap.engine.services.rmi_p4.DispatchImpl._run(DispatchImpl.java:19
3)
at com.sap.engine.services.rmi_p4.server.P4SessionProcessor.request(P4Se
ssionProcessor.java:122)
at com.sap.engine.core.service630.context.cluster.session.ApplicationSes
sionMessageListener.process(ApplicationSessionMessageListener.java:33)
at com.sap.engine.core.cluster.impl6.session.MessageRunner.run(MessageRu
nner.java:41)
at com.sap.engine.core.thread.impl3.ActionObject.run(ActionObject.java:3
7)
at java.security.AccessController.doPrivileged(Native Method)
at com.sap.engine.core.thread.impl3.SingleThread.execute(SingleThread.ja
va:100)
at com.sap.engine.core.thread.impl3.SingleThread.run(SingleThread.java:1
70) -
To get the last 12 months from the input date
Hi ,
Is there any way in sql to get the last 12 months date if i input the sysdate.
LIke I will input sysdate (16-aug-13 ) and I need to get 16-jul-13,16-jun-13,16-may-13 like this.
This has to be done in the sql only with out using pl/sql
Regards,
Papiselect listagg(to_char(dt,'dd-mon-yy'),', ')
within group (order by dt desc) dates
from (select add_months(date '2013-08-16',level*-1) dt
from dual connect by level <=12
DATES
16-jul-13, 16-jun-13, 16-may-13, 16-apr-13, 16-mar-13, 16-feb-13, 16-jan-13, 16-dec-12, 16-nov-12, 16-oct-12, 16-sep-12, 16-aug-12 -
Showing last n months data based on prompt
Hi,
I have a "reporting month" prompt like Mar'13 .The report should return last 12 months data for all the measures based on "Reporting Month" prompt and my result will look like below:
Measures Mar' 13 Feb 13 Jan 13 ....
CORP 1345 1444 1555
ERP 675 877 5678
I have used a pivot view to get the table view like this but i am not sure how to use the logic for showing all Months .Kindly suggest.Hi,
You can achive this at answers level with the help of presentation variable using "Last N months(Rolling months) data By year-month prompt in OBIEE".
pl follow the below post.
http://shivabizint.wordpress.com/2008/09/19/rolling-months-data-for-year-month-prompt-in-obiee/
thanks -
Report to pull next call date for all equipment
Hello,
Is there a report in SAP to get all the next call date for all of our equipment within our company?
Thankshi
in IP24 use the multiple selection to select all the equipment and in the selection screen under maintenance dates select maintenance status as W/ and execute system will display the next planned date for the equipment selected -But with all the call object which are on hold
regards
thyagarajan -
Creation of a Query to show the values for the current month and the last 12 months data.
Dear All,
Good day!
I have to create a Query with the below requirement.
I have to create a Query to show the values for the current month and the last 12 months data.
Can you please guide me how to achieve this ??
thank you,
Regards,
HemaHema
explain the exact problem..? as you mentioned you want to create query to show values for current month and last 12 months.. so I think you want to show values for 12 months from current data.. you can achive this by multiple way..
you can have selection screen and field with date .. and restrict based on system current date and 12 months before or you can handle this at your target.. .. I mean there are multiple ways to restrict data by date range..
for some more hints..
http://www.forumtopics.com/busobj/viewtopic.php?t=34393&sid=7fba465d0463bf7ff5ec46c128754ed6
http://businessintelligence.ittoolbox.com/groups/technical-functional/cognos8-l/how-to-display-last-12-months-in-report-based-on-todays-date-3231850
http://scn.sap.com/thread/3217381
search on SDN you will get many other ways..
Thanks,
Bhupesh -
How to get last 24 months data (if user not enter any kind of information)
Hi all,
I am want a report such that
1. if user does not enter months he has to get last 24 months data(from current month)
eg1.
Sales
currentmonth 300
currentmonth-1 400
currentmonth-20 500
2. if user enter months he has to get required months data(from current month)
eg1.assume that user entered the interval of last two months.
Sales
currentmonth 300
currentmonth-1 400.
friends please me in desinging this query.
It's very urgent,waiting for responses.
Thanks,
James.Hi james,
1. if user does not enter months he has to get last 24 months data(from current month)
ANS: U have to create variable Of Currentmonth with The following
Process Type: SAP Exit
Variable Represent: Single value
Variable Entry: Optional
Check chekboxes for <b>Ready for Input</b> & Can be change in Query navigation.
b) After this u have to give offsets by restricting this variable
2. if user enter months he has to get required months data(from current month)
ANS:
For this U have to use Process Type: User-exit( User Entry)
& After that specify the offsets by restriction.
Thanks,
kiran.
Message was edited by:
kiran manyam -
Hi,
Requirement:
Want to show last three months data dynamicaly based month value seleted in prompt. ex: When Septemper is selected report should show, Sep, Aug, Jul
tried using ago function but i want to use three measure columns. So is there way using single measure column and achieving.
Thanks,
SatheeshSatheesh Kumar wrote:
Hi,
Requirement:
Want to show last three months data dynamicaly based month value seleted in prompt. ex: When Septemper is selected report should show, Sep, Aug, Jul
tried using ago function but i want to use three measure columns. So is there way using single measure column and achieving.
Thanks,
SatheeshSatheesh, I have a question for you. It is the same as the comment left on the article in the link that @user gave you. Like that link -- which doesn't work for all scenarios, how are you accounting for say the month of January? Without a "year" included, you cannot always "subtract 3" to get "3 months ago." Does "month" always correspond to the current year?
Finally, what are the values of the column the filter is to be applied? All these are important to know if you want help on this. Try again. Thanks. -
No more "current and next month" list on left of iCal
Since the upgrade to Lion, the current and next month list on the left is gone. When I want to reschedule an event, I used to look on the left to see the dates in the next month, or current month if in week view etc .... now it's not there. If I want to change a date, I have to look at another calendar on my wall to reschedule. Can this list be put back on the left?
Mark,
You may want to experiment using the "Year" view. There is a keyboard shortcut (⌘4) for accessing that view.
Can this list be put back on the left?
Let Apple know about your suggestion using Apple - iCal - Feedback. -
Hi loading last 2 months data using abap routine
we are planning to write a routine in infopackage level,
using the option 6-ABAP routine, to select the last 2 month data ,
we have the time characteristics 0CALMONTH, At present we managing the load by manually changing the selection for last 2 month every time ,
It would be a great help if anybody can show a sample code to select last 2 month data,
Thanks,Hi,
data: l_idx like sy-tabix.
DATA: lv_calmonth LIKE /BI0/SCALMONTH-CALMONTH.
DATA: lv_day TYPE DATS.
"previous month
lv_day = SY-DATUM.
lv_day+6(2) = '01'.
lv_day = lv_day - 1.
lv_calmonth = lv_day(6).
READ TABLE l_t_range with key fieldname = 'CALMONTH'.
l_idx = sy-tabix.
MOVE lv_calmonth TO l_t_range-low.
MODIFY l_t_range INDEX l_idx.
"previous month - 1
lv_day+6(2) = '01'.
lv_day = lv_day - 1.
lv_calmonth = lv_day(6).
MOVE lv_calmonth TO l_t_range-low.
APPEND l_t_range.
p_subrc = 0.
let me know if this works.... not sure about the last append.
Olivier. -
Next release date for C++ Parser- URGENT-
What is the next release date for the C++ Parser??
The bug in 2.0.3.0.0 regarding broken DOS filenames is preventing us from shipping a build to Apps that is required next week.
Otherwise what is the most recent C++ build that offers:
a) A fix for entity reference parsing(&apos,")correctly.
b) DOS filename compatibility(i.e c:\cleo.xml).
This is very urgent so your response is much appreciated.
nullIt is scheduled to be released by the end of this week.
Oracle XML Team
null -
Previous month data in WebI Report
Hi All,
I have a universe created on a Bex Query. I don't have any variables created in the Bex Query. I have to create a WebI report with Calendar Year/Month as selection and depending on what user enters, i have to display Cost for the month entered by the user and cost for (month -1 ). For eg. if the user enters Feb 2009, then the report should display Cost for Jan 2009 and Feb 2009. I have created a filter for Calendar Year/Month. How do i bring previous month data in the report ? I don't have to modify the Bex Query. I have to achieve it on the BO side. Can you guys help on this problem.
Thanks,
SaachiHi,
There is a restriction in BO when you use it with SAP.
When the user filters the data for FEB 2009, you will not be able to get data for JAN 2009 as it does
not go again to the Bex query to fetch this data.
The only workaround as of now to this is to bring all the data using Bex query by having a filter
at the BO Query level where you say Cal year/month key = (From prompt) or
Cal year/month key <> #.
This is because it considers Cal year/month as string and so even at the universe level we will not
be able to create a previous month formula.
I hope this helps.
Thanks,
Kartik -
Hi. How do i return date records of next month?
I am aware i may need sysdate.
At the moment i have been trying:
WHERE delivery_date = ADDMONTHS (sysdate, 1);
No avail.
Ideas?Hello
If you mean you want to set up a range from the start of next month to the end of next month. This shows what happens when you apply add_months to sysdate
SQL> select sysdate from dual;
20-NOV-05
SQL> select add_months(sysdate,1) from dual;
20-DEC-05
--Truncate sysdate to the first day of the month and then add 1 month
SQL> select add_months(trunc(sysdate,'MM'),1) from dual;
01-DEC-05
--do the same, but use LAST_DAY to get the date of the last day next month
SQL> select add_months(trunc(sysdate,'MM'),1),last_day(add_months(trunc(sysdate,'MM'),1)) from dual;
01-DEC-05 31-DEC-05So with that in mind, you probably need to do something like
WHERE
delivery_date BETWEEN add_months(trunc(sysdate,'MM'),1) AND last_day(add_months(trunc(sysdate,'MM'),1));If you just want to get rows for "this" day next month you may well need to set a date range up especially if the delivery_date has not been truncated to set the time portion to 00:00:00
WHERE
delivery_date = ADD_MONTHS(TRUNC(sysdate),1))
WHERE
delivery_date >= ADD_MONTHS(TRUNC(sysdate),1))
AND
delivery_date < ADD_MONTHS(TRUNC(sysdate),1)) + 1HTH
David
Message was edited by:
david_tyler -
Variable Exit - Last Three months date range based on Sy-datum
Hi
I have a requirement to filter last 3months data based on sy-datum. I have a variable filter on Posting Date.
For e.g. Today is 20110622
I have to determine below range: When users run the report prompt should be auto filled with below date range.
From Value: 20110301
To Value : 20110531
From sy-datum I can find the first day of the current month - In this scenario 20110601 (I'll replace last 2 characters with "01").
If I subtract "-1" I'll get the To Value: 20110531
Question is to get the "From Value". If I subtract 90days from To value, it will work for few months.
For e.g. If my To value is Feb 28th and if I subtract 90days, I may get a different answer.
Is there any better approach to determine this date range?
Thanks for your help.
Best Regards,
SreeHi Sree,
Pleae find this approach and compare
data : l_date type sy-datum,
l_startdate type sy-datum,
l_endate type sy-datum,
l_startmonth(6) type c,
l_endmonth(6) type c,
l_date = sy-datum. say "20110622
l_endmonth = sydatum(6) "201106
Pass year month and get previous month using this standard .
CALL METHOD cl_rs_time_service=>shift_year_month
EXPORTING
i_year_month = l_endmonth
i_shift = -1
RECEIVING
r_year_month = l_endmonth
EXCEPTIONS
failed = 1
OTHERS = 2.
"l_endmonth = 201105.
CALL METHOD cl_rs_time_service=>shift_year_month
EXPORTING
i_year_month = l_endmonth
i_shift = -2
RECEIVING
r_year_month = l_startmonth
EXCEPTIONS
failed = 1
OTHERS = 2.
"l_startmonth = 201103
l_startdate(6) = l_startmonth.
l_startdate+6(2) = '01'.
"l_startdate = 20110301
We got startdate in and we want to get enddate , but we got endmonth ...
now we need to get last date of the endmonth.
Use this function module SLS_MISC_GET_LAST_DAY_OF_MONTH and u can get it. Input should be date.
so put l_enddate+6(2) = '01'.
l_enddate(6) = l_endmonth.
now pass end date to the Function module and this will return the end date of the month.
So you get l_startdate and l_enddate as you require. This will work for leap years or feb 28 days what ever...
Regards
vamsi
Edited by: vamsi talluri on Jun 22, 2011 10:06 PM -
Need to Create a Last 12 Months Variable for Custom Dimension
Hi everybody
Once again, I need your good help for an issue I'm facing. In one of our Cube, we have some Date Dimension sthat we've created ourselves (a ZCXXXXX dimension). For one Dimension, Ii need to create a variable that is giving me, automaticaly, the Last 12 Months excluding Current Month (same as the 0CML12LM provided by SAP) without any manual entry done by the user via the Variable Entry Screen.
I don't want to use offset because I don't want to allow any Manual intervention for my users because it is a report start via RRI.
Please let me know if you are aware on how to do this!
Thanks
Eric L.Hi Arun
My problem is that my report is counting Incident per supplier per Month. We have a Key Figure that is doing the Total of incident with a Vendor Variable. So, for a given supplier, if there is no incident for the Incident Month, it won't display in the Result Page. Also, My report is dynamic so I'can not fix a Structure. On the other hand, I never used Strucutre, so I'm not really aware on how using this and if it will answer my need.
If you can give me more details, maybe I'll be able if a Structure is my solution.
Regards
Eric L.
Maybe you are looking for
-
Hello team, does anybody have the migration path to migrate an 8170 database to 11g R2? Document id 785351.1 talks about migrating from 92 to 11gr2. but i cant find any document to migrate from 8i. Thanks in advance.
-
I just bought a new Intel iMac and will need to transfer some files from the wife's purple G3 iMac. I've read countless threads about how to do this and am more confused than ever. Do I need a crossover Ethernet cable? Firewire? A simple explanation
-
During client setup installation the message "u201Csetup has failed to automatically login to the server please enter correct login informationu201D appears and it does not allow the completion of the installation. We are using MSSQL Server 2005 in W
-
Forefront TMG detected a proxy server loop. There may be a problem in the configuration of the Forefront TMG Web chaining policy. Alternatively, in Enterprise Edition, when CARP is enabled and there are intermittent interruptions of intra-array conne
-
HT3669 Scanning problems with v2.17?
I am running an Epson Stylus SX438W all-in-one. Not a very common model. I discover today that when scanning, it is completing the preview scan, but when attempting the actualscan, the message" Done Scanning Selected Areas" displays. Any ideas. There