Updation of SO Confirmed Delivery date based on GR date for BANC parts
Dear All,
Would appreciate an answer on the following issue:
For Back to back/Indiv Purchase Order parts(BANC) the confirmed delivery date in the SO is updated based on the Order Acknowledgement date sent by the vendor for the corresponding PO generated for the SO. If the the vendor happens to deliver the parts in advance of the OA date(it happens quite often), the parts wait in stores till the confirmed delivery date is reached on the SO even thugh the original requested date on the Sales order is long past. If there is an order acknowledgement date in the system, at the time of GR, a warning message comes, but as our system is a high volume systme it is not possible to update the date in SO manually. Is there a way we can update the confirmed delivery date in the SO based on the Goods receipt date automaticall through config or a batch job?
Thanks
Suman
Dspsac,
Delivery date can be any date. For instance, if your customer insisted on a Sunday delivery, you would accommodate him, regardless of any calendar.
From the delivery date, the system counts backwards USING THE FACTORY CALENDAR ASSIGNED TO THE ROUTE by the number of days in the route. You have to consult the FC assigned to your Route to determine if the GI date has been properly calculated.
From the GI date, the system counts backward Pick/pack time, using the shipping point calendar, to arrive at Material availability date.
Calculations are explained in SAP online help
[Transportation and Delivery Scheduling|http://help.sap.com/erp2005_ehp_04/helpdata/EN/dd/5607e7545a11d1a7020000e829fd11/frameset.htm]
Regards,
DB49
Similar Messages
-
FM to get previous sunday date based on current date(SY-DATUM)
hi all,
Is there any function module to get the previous sunday date based on current date(sy-datum)?
Regards,
Kapil SharmaHi Kapil,
You can follow the logic below:
data:
l_date like sy-datum, **TODAY
l_date2 like sy-datum, **Previous Sunday
data:
l_daynr like HRVSCHED-DAYNR.
*Get today's date
l_date = sy-datum.
*Gey today's day (Monday, Tuesday, etc.)
CALL FUNCTION 'HRIQ_GET_DATE_DAYNAME'
EXPORTING
langu = 'EN'
date = l_date
IMPORTING
daynr = l_daynr.
CASE l_daynr.
*If it is Monday
WHEN 1.
-Subtract 2 days for the previous Sunday
CALL FUNCTION 'HR_SEN_CALE_DAYS_DATE'
EXPORTING
id_date = l_date
id-operator = '-'
is_duration = 2
IMPORTING
ed_date = l_date2.
*If it is Tuesday
WHEN 2.
CALL FUNCTION 'HR_SEN_CALE_DAYS_DATE'
EXPORTING
id_date = l_date
id-operator = '-'
is_duration = 3
IMPORTING
ed_date = l_date2.
*If it is Wednesday
WHEN 3.
CALL FUNCTION 'HR_SEN_CALE_DAYS_DATE'
EXPORTING
id_date = l_date
id-operator = '-'
is_duration = 4
IMPORTING
ed_date = l_date2.
*If it is Thursday
WHEN 4.
CALL FUNCTION 'HR_SEN_CALE_DAYS_DATE'
EXPORTING
id_date = l_date
id-operator = '-'
is_duration = 5
IMPORTING
ed_date = l_date2.
*If it is Friday
WHEN 5.
CALL FUNCTION 'HR_SEN_CALE_DAYS_DATE'
EXPORTING
id_date = l_date
id-operator = '-'
is_duration = 6
IMPORTING
ed_date = l_date2.
*If it is Saturday
WHEN 6.
CALL FUNCTION 'HR_SEN_CALE_DAYS_DATE'
EXPORTING
id_date = l_date
id-operator = '-'
is_duration = 7
IMPORTING
ed_date = l_date2.
*If it is Sunday
WHEN 7.
CALL FUNCTION 'HR_SEN_CALE_DAYS_DATE'
EXPORTING
id_date = l_date
id-operator = '-'
is_duration = 8
IMPORTING
ed_date = l_date2.
ENDCASE.
Regards,
Dilek -
FM to get the previous sunday date based on current date(sy-datum)
hi all,
Is there any function module to get the previous sunday date based on current date(sy-datum)?
Regards,
Kapil Sharma
Moderator Message: Basic date related questions are not allowed
Edited by: Suhas Saha on Sep 19, 2011 11:39 AMHi,
There are function modules to find out the current day of the week depending on sy-datum. These are as below:
1. DATE_COMPUTE_DAY - Returns a number indicating what day of the week the date falls on. e.g. Monday is returned as a 1, Tuesday as 2,...., Sunday as 7.
2. RH_GET_DATE_DAYNAME - Returns the day based on the date provided, e.g. Monday, Tuesday,..., Sunday.
Using any of the above, if you can find out the current day, then you can calculate and compute the date of the previous Sunday.
My observation is that using the first FM might make the calculation simpler.
Hope this is of help to you.
Regards,
Shayeree -
Invoice Date Based on POD Date and Requested Delivery Date
Hello Experts,
Could you please Help me How to get the Billing date in the invoice document based on POD date if the POD Report has been Posted , If not the system should pick up the requested delivery date.
Thanks for your timeHi,
Create an copy control routine (T.Code VOFM) as assign in copy control setting between Delivery doc to billing docuement (T.code VTFL).
The new routine will be created with copy of existing routine assign under "Copying requirements" at item level, and assign on same place.
Pl take help of ABAPer to write the new routine.
regards
Vivek.
Edited by: Vievk Vardhan on Jan 7, 2010 1:50 PM -
Date based Resultset and Date display
Hi
I have two jsp pages. In first page user selects a Date and name, based on that 2nd jsp display a resultset in a table. I want to Display Selected name and Date on 2nd Page. I done it for name and unable to show the Date and query is also to be modified.
Here is code for my two jsp pages:
first.jsp
<%@ taglib uri="http://java.sun.com/jstl/sql" prefix="sql" %>
<%@ taglib uri="http://java.sun.com/jstl/core" prefix="c" %>
<%@ include file="DataSource.jsp" %>
<html>
<head>
<title>abcd</title>
<script type="text/javascript" language="javascript">
function HTML(p){
if(!p){
/*default*/
p='A action align alt B background Base bgcolor BIG BLINK BODY border bordercolor bordercolordark bordercolorlight Br cellpadding cellspacing checked color cols colspan compact content dir DIV enctype face FONT FORM H1 H2 H3 H4 H5 H6 HEAD height Hr href hspace HTML I id Img Input lang language leftmargin LI marginheight marginwidth maxlength Meta method name NOSCRIPT noshade nowrap OL onblur onchange onclick onfocus onload onmouseout onmouseover onreset onselect onsubmit onunload OPTION P PRE profile readonly rows rowspan SCRIPT SELECT size SMALL SPAN src start STRIKE STYLE style SUB SUP TABLE target TD TEXTAREA TH TITLE title topmargin TR TT type U UL valign value vspace width wrap'
String.prototype.write=function(){
document.write(this);
return this
String.prototype.alert=function(){
window.alert(this);
return this
String.prototype.status=function(){
window.status=this;
return this
var x=[
function(W){var q=String.fromCharCode(34);return ' x='+q+((typeof(W)!='undefined')?W:'x')+q}/*attr*/,
function(W){return '<x'+((typeof(W)!='undefined')?W:'')+' />'}/*tag*/,
function(W){return '<x'+((typeof(W)!='undefined')?W:'')+'>'+this+'</'+'x>'}/*container*/,
function(W){var o='<x'+((typeof(W)!='undefined')?W:'')+' />';return o+this.join(o)}/*tags*/,
function(W){var o='<x'+((typeof(W)!='undefined')?W:'')+'>';var c='</'+'x>';return o+this.join(c+o)+c}/*containers*/
var j=[];
var f=0;
var a=p.split(' ');
var t,u,l;
for(var i=0;i<a.length;i++){
t=a;
u=t.toUpperCase();
l=t.toLowerCase();
if(t==l){
/*attr*/
j[f]='window.'+u+'='+x[0]
else if(t==u){
/*container;containers*/
j[f]='String.prototype.'+u+'='+x[2]+';Array.prototype.'+u+'='+x[4]
else{
/*tag;tags*/
j[f]='window.'+u+'='+x[1]+';Array.prototype.'+u+'='+x[3]
/*specific*/
j[f]=j[f].replace(/x/g,l);
f++
window.status='HTML() bookmarklet library: Copyright (c) 2002-'+(new Date()).getFullYear()+', by Richard Edwards. ['+f+' tag/attrs added] ';
/*implement!*/
eval(j.join(';'))
HTML();
</script>
<script type="text/javascript" language="javascript">
function init(){m='January February March April May June July August September October November December'.split(' ');wd='Su M Tu W Th Fr Sa'.split(' ');lom=[31,28,31,30,31,30,31,31,30,31,30,31];sz=25;js='javascript';fn=[function(F){},function(F){DATE=new Date(F.date.value);if(isNaN(DATE.valueOf())){DATE=new Date()};M=DATE.getMonth();D=DATE.getDate();Y=DATE.getFullYear();lom[1]=28;if((Y%/**/4==0)&&((Y%/**/100>0)||(Y%/**/400==0))){lom[1]++}},function(F){if(D>lom[M]){D=lom[M]};F.date.value=(M<9?'0':'')+(1.0+M)+'/'+(D<10?'0':'')+D+'/'+Y;dv.value=F.date.value;if(opener.Page){opener.document.forms[0][dv.name].value=F.date.value}},function(){F=this.form;fn[1](F);M=this.selectedIndex;fn[2](F);fn[0](F)},function(){F=this.form;fn[1](F);D=this.value;fn[2](F);fn[0](F)},function(){F=this.form;fn[1](F);Y=this.value;fn[2](F);fn[0](F)},function(F){fn[1](F);var f=new Date(Y,M,1);var x=1-(f.getDay());for(var i=0;i<49;i++){F.d[i].value=(i<7?wd[i]:'');F.d[i].onclick=this;};for(var i=1;i<=lom[M];i++){w=Math.floor((i-1)/7);n=7+i-x;F.d[n].value=i;F.d[n].onclick=fn[4];if(i==D){F.d[7+i-x].focus()}};for(var i=0;i<F.m.length;i++){F.m[i].selected=(i==M)};F.m.onchange=fn[3];F.y.value=Y;F.y.onchange=fn[5];F.y.onblur=fn[5];fn[2](F)}];fn[0]=fn[6]};init();function popCal(datevalue){if(!datevalue){dv={name:'Today',value:(new Date())}}else{dv=datevalue};var c=ALIGN('center')+HEIGHT(sz);var h=(m.OPTION().SELECT(NAME('m'))+INPUT(TYPE('text')+SIZE(4)+NAME('y'))+INPUT(TYPE('hidden')+NAME('date')+VALUE(dv.value))).TD(COLSPAN(7)+c);var b=INPUT(TYPE('button')+NAME('d')+STYLE('width:'+sz+';height:'+sz)+WIDTH(sz)+c);var r=[b,b,b,b,b,b,b].TD(WIDTH(sz*7)+c);h=[h,r,r,r,r,r,r,r].TR(c).TABLE(BORDER('0')+CELLSPACING('0')+CELLPADDING('0')+c).FORM(NAME('frm')+ACTION(js+'://'));h+=(init+';init();dv=opener.dv;fn[0](document.forms.frm);').SCRIPT(LANGUAGE(js)+TYPE('text/'+js));window.open('','cal'+(new Date()).valueOf(),'height='+sz*9+',width='+sz*8).document.write(h)};
</script>
</head>
<body bgcolor=lightblue>
<center><h1>xyz</h1></center>
<hr>
<br>
<p>
<p>
<p>
<p>
<h4>Select a date: </h4>
<script type="text/javascript" language="javascript">
(INPUT(NAME("DV")+READONLY())+INPUT(TYPE("button")+VALUE("Calendar..")+ONkLICK("popCal(this.form.DV)"))).FORM().write();
</script>
<p>
<p>
<br>
<form method=post action="second.jsp">
<sql:transaction dataSource="${example}">
<sql:query var="Power">
select unique trader_name from exchange_deal where unit_of_measure='mwh'
</sql:query>
</sql:transaction>
<h4><p>Select a Trader:
<select Name = "TraderDrop">
<c:forEach var="row" items="${Power.rows}">
<option size="20"><c:out value="${row.Trader_name}"/></option>
</c:forEach>
</select>
<p>
</h4>
<br>
<input type="submit" value="SUBMIT"/>
<input type="reset" value="CANCEL"/>
</form>
</body>
</html>
Second jsp
<%@ taglib uri="http://java.sun.com/jstl/sql" prefix="sql" %>
<%@ taglib uri="http://java.sun.com/jstl/core" prefix="c" %>
<%@ include file="DataSource.jsp" %>
<html>
<head>
<title>abc</title>
</head>
<body bgcolor=lightblue>
<center><h1>xyz</h1></center>
<hr>
<form name="input" action="pqr.jsp"
method="get">
<c:set var="s" value="${param.TraderDrop}" />
<h3>Trader : <c:out value="${s}" /></h3>
<c:set var="d" value="${param.date}" />
<h3>Trade Date: <c:out value="${d}" /></h3>
<sql:transaction dataSource="${example}">
<sql:query var="Power">
SELECT DEAL_ID, DEAL_TYPE, EXCHANGE_NAME, HUB_NAME, ORGINATING_APPLICATION, PRODUCT_ID, TAKER_COMPANY FROM ENYWARE.EXCHANGE_DEAL where TRANSACTION_TIMESTAMP > sysdate - 3 and trader_name = '<c:out value="${s}" />'
</sql:query>
</sql:transaction>
<table border="1">
<%-- Get the column names for the header of the table --%>
<tr>
<c:forEach var="columnName" items="${Power.columnNames}">
<th><c:out value="${columnName}"/></th>
</c:forEach>
</tr>
<tr>
<c:forEach var="column" items="${row}">
<td><c:out value="${column.value}"/></td>
</c:forEach>
</tr>
</c:forEach>
</table>
</form>
</body>
</html>
I am using JavaScript calendar for entering date in a Text box.
Please review code and help me.
Thanks in Advance
SuryaAnitha123 wrote:
Hi
Thanks for your reply..
We execute our application using a batch file which holds the main class file to be executed as below :
batch file content as below :
set PATH=.\_jvm\bin
set JAVA_HOME=.\_jvm
set CLASSPATH=.\_jvm\lib\rt.jar;.\_jvm\lib\itext.jar
java -cp %CLASSPATH%;.\classes xx.yy.zz.Ourmainclass
Here how can i set the time zone as users time zone? we don't use any manifest file for our application..can you please guide me on the same..Very Good...Then here is your answer..
set PATH=.\_jvm\bin
set JAVA_HOME=.\_jvm
set CLASSPATH=.\_jvm\lib\rt.jar;.\_jvm\lib\itext.jar
java -Duser.timezone=Asia/Calcutta -cp %CLASSPATH%;.\classes xx.yy.zz.OurmainclassIf this will solve your problem.. don't forget to reward duke stars...please.. -
Calculation of due date based on Business Days for FICA documents
Hi All,
I am working on project where SD - FICA integration is in picture. We post some charges through SD and FICA document gets posted on relevant Contract Account.
Normally we create Sales Order using transaction VA01 and then we do Billing for this Sales Order through VF01. After billng is done, FICA document automatically gets generated.
We have following requirement to be fulfilled.
For the SD bills posted as above, I want to calculate due date of these bills based on Business Days for FICA document generated (SAP Standard calculate due date based on Calander days). We can use factory calander for calculating business days in relevant function module.
I have checked in the system and it seems that event 1330 ( FM - ISU_DUE_DATE_DETERMINE) is not working in this scenario. Is there any other FM which I can use?
Can anyone help me on this?
Regards,
PradeepHello Praeva ,
The event 1330 has a sample FM FKK_SAMPLE_1330. It doesnt even have a Standard Function Module.
You need to create a Installation-Specific FM and put your code to determine the Due Date based on the logic.
Rgds
Ram Kumar. -
Last month end date based on current date
Hi,
How to show last month end date based on the current date.
Eg:
Current date = "08/26/09"
Var- Last Month End Date = "07/31/09" etc...,
Please help me how to get it...
Thank You!Good to hear that it worked for you. but not for me.
I tried like this:
1st::
1. var1= ToDate("06/30/09","MM/dd/yyyy")
2.Var2= RelativeDate([Var1];-DayNumberOfMonth([Var1]))
result: 5/30/09
2nd:
RelativeDate('6/30/2009';-DayNumberOfMonth('6/30/2009'))
result: 5/30/09
Am working on SAP OLAP cubes.
Please help me where am going wrong....
Thank You! -
How to schedule report filtered by dynamic date based on the date the Agent runs
Hello
I have a question about delivering report using OBIEE agent.
If i am running an agent today to deliver report A, can I get report A based on Last Monday's date or any dynamic dates?
For example, say today is Dec 18th 2013 and my agent is running according to how I set the schedule. Now the deliver content will have report A being delivered. Now report A has a date column, normally this column is filtered by current date. But if it's delivered through agents to various users, Report A's data should be the previous Monday, so in this case Dec 9th 2013. When this agent is run again said on Dec 27th 2013, then report A should be filtered by Dec 16th 2013, which is the previous monday of Dec 27th.
Can something like this be achieved in OBIEE 11G?
Thanks in advance.Yala,
Not a straight forward way
1) Let the report run through Agent with Current Date filter
2) once it ran for the first time you can see IBOT name/last run time(LAST_RUNTIME_TS) in S_NQ_JOB
Create a repository variable 'last_run_agent' using below sql to get max(LAST_RUNTIME_TS)
select max(LAST_RUNTIME_TS) from s_nq_job where name = 'AGENT_NAME';
Edit the analysis report with current date filter and modify the filter condition accordingly to filter on newly created repository variable
Thanks,
Saichand -
Simple select to get data based on a date
Hi all
I have written some data to a table and am having issues trying to do a select and get that data based on the query.
I want to filter on a column called: TIMESTAMP based on the condition that the data was written to the DB on the following date:
01-OCT-09 10.47.35.597914000
I thought this would be enough:
select * from tableX
where current_value = 999
and TIMESTAMP = '01-Oct-2009'
I know the 999 exists because if I take out the last line I get the data I want.
A basic question I know but any help much appreciated.Dird wrote:
Hi Boneist,
When using > or < I use TO_DATE with DD-MON-YYYY or whatever format I need. TO_CHAR just comes to mind naturally when I need an equality test.
MikeHmm....
Let's see ->
satyaki>
satyaki>select * from v$version;
BANNER
Oracle Database 11g Enterprise Edition Release 11.1.0.6.0 - Production
PL/SQL Release 11.1.0.6.0 - Production
CORE 11.1.0.6.0 Production
TNS for 32-bit Windows: Version 11.1.0.6.0 - Production
NLSRTL Version 11.1.0.6.0 - Production
Elapsed: 00:00:00.02
satyaki>
satyaki>
satyaki>select * from emp;
EMPNO ENAME JOB MGR HIREDATE SAL COMM DEPTNO
7369 SMITH CLERK 7902 17-DEC-80 800 20
7499 ALLEN SALESMAN 7698 20-FEB-81 1600 300 30
7521 WARD SALESMAN 7698 22-FEB-81 1250 500 30
7566 JONES MANAGER 7839 02-APR-81 2975 20
7654 MARTIN SALESMAN 7698 28-SEP-81 1250 1400 30
7698 BLAKE MANAGER 7839 01-MAY-81 2850 30
7782 CLARK MANAGER 7839 09-JUN-81 2450 10
7788 SCOTT ANALYST 7566 19-APR-87 3000 20
7839 KING PRESIDENT 17-NOV-81 5000 10
7844 TURNER SALESMAN 7698 08-SEP-81 1500 0 30
7876 ADAMS CLERK 7788 23-MAY-87 1100 20
EMPNO ENAME JOB MGR HIREDATE SAL COMM DEPTNO
7900 JAMES CLERK 7698 03-DEC-81 950 30
7902 FORD ANALYST 7566 03-DEC-81 3000 20
7934 MILLER CLERK 7782 23-JAN-82 1300 10
14 rows selected.
Elapsed: 00:00:00.07
satyaki>
satyaki>
satyaki>select *
2 from emp
3 where hiredate < to_date('01-MAR-1981','DD-MON-YYYY');
EMPNO ENAME JOB MGR HIREDATE SAL COMM DEPTNO
7369 SMITH CLERK 7902 17-DEC-80 800 20
7499 ALLEN SALESMAN 7698 20-FEB-81 1600 300 30
7521 WARD SALESMAN 7698 22-FEB-81 1250 500 30
Elapsed: 00:00:00.00
satyaki>
satyaki>select *
2 from emp
3 where to_char(hiredate,'DD-MON-YYYY') < {noformat}'{noformat}01-MAR-1981{noformat}'{noformat} ;
no rows selected
Elapsed: 00:00:00.00
satyaki>
satyaki>So, as you can clearly see considering date as string may cost you heavy. Or don't you think so?
Regards.
Satyaki De.
N.B.: Some problem with the formatting. So, date is not appearing in the second case. :( -
Calendar with preselected dates based on current date
Can we get the calendar to be prepopulated with todays' date and today-7 date as the default before it starts running the initial queries when I log into dashboard.
I have a calendar date range based on which my chart displays metrics. If I dont choose anything its picking up all the data first before I choose something
Your help is always appreciated.I apologize I read your post too quickly and misunderstood your question. Unfortunately, I thought you were referring to a dashboard you had created and asking about setting up default dates for your bind variables/parameters.
Well I'll have to leave this one to someone else. Sorry I couldn't be more help.
David -
Return latest transaction data, based upon transaction dates.
I appreciate I'm being a little dense here, and I have searched, read, and tried out a few different solutions I've seen give around the place. However; I think I'm struggling more with the naming conventions and logic of other people queries than you might in understanding mine (here's hoping!)
I have a huge table, which contains a record for every transaction which has an effect on our inventory (yup - BIG table!)
For a given transaction type 'CHC' (CHange Costs) I want to return the Part code, Transaction Date and Transaction cost of the LAST TWO changes.
Because its to be used for tracking updates to the cost of materials, and further for calculating the ongoing effect of these, I just need the two for now.
So,
Table is I50F
Columns required are
I50PART - [Part Code|http://forums.oracle.com/forums/]
I50TDAT - [Transaction Date|http://forums.oracle.com/forums/]
I50UCOST - [Price changed to|http://forums.oracle.com/forums/]
I50TRNS - [Transaction Type - we just want CHC]
Sample Data (Including just columns we are interested in)
I50PART I50TDAT I50UCOST I50TRNS
BACCA001 08/03/2006 07:34:51 0.08829 CHC
BACCA001 25/07/2007 08:26:30 0.10329 CHC
BACCA001 10/04/2008 16:29:02 0.10639 CHC
BACCA003 20/06/2006 12:22:30 0.16814 CHC
BACCA003 25/07/2007 08:26:54 0.17024 CHC
BACCA003 10/04/2008 13:30:12 0.17535 CHC
BACCA004 28/08/2007 15:46:03 0.06486 CHC
BACCA004 28/08/2007 15:49:15 0.06328 CHC
BACCA004 30/10/2008 09:22:40 0.06952 CHC
BACCA004 13/01/2009 09:09:07 0.06867 CHC
BACCA005 25/07/2007 08:27:24 0.06715 CHC
BACCA005 10/04/2008 15:45:14 0.06916 CHC
BACCA005 30/10/2008 09:05:17 0.07453 CHC
BACCA005 13/01/2009 09:06:49 0.07275 CHC To take a part in isolation, BACCA005;
I'm interested in the last two records.
It makes sense for there to be two records output per part at this stage, as it may be that the powers that be decide that they want the last 3, or 4, or whatever (I'm sure everybody has similar experiences with beancouters)
Is it A) Easy, and B) relatively efficient. There are 2.4m records in the table.
If I've been stupid and not included enough info, please do [metaphorically] poke me in the eye, and I'll pad out a bit.
Thanks ever so much for reading - and even more so if you can help!
Cheers
JAnalytic functions FTW!
with I50F as (select 'BACCA001' I50PART, to_date('08/03/2006 07:34:51', 'dd/mm/yyyy hh24:mi:ss') I50TDAT, 0.08829 I50UCOST, 'CHC' I50TRNS from dual union all
select 'BACCA001' I50PART, to_date('25/07/2007 08:26:30', 'dd/mm/yyyy hh24:mi:ss') I50TDAT, 0.10329 I50UCOST, 'CHC' I50TRNS from dual union all
select 'BACCA001' I50PART, to_date('10/04/2008 16:29:02', 'dd/mm/yyyy hh24:mi:ss') I50TDAT, 0.10639 I50UCOST, 'CHC' I50TRNS from dual union all
select 'BACCA003' I50PART, to_date('20/06/2006 12:22:30', 'dd/mm/yyyy hh24:mi:ss') I50TDAT, 0.16814 I50UCOST, 'CHC' I50TRNS from dual union all
select 'BACCA003' I50PART, to_date('25/07/2007 08:26:54', 'dd/mm/yyyy hh24:mi:ss') I50TDAT, 0.17024 I50UCOST, 'CHC' I50TRNS from dual union all
select 'BACCA003' I50PART, to_date('10/04/2008 13:30:12', 'dd/mm/yyyy hh24:mi:ss') I50TDAT, 0.17535 I50UCOST, 'CHC' I50TRNS from dual union all
select 'BACCA004' I50PART, to_date('28/08/2007 15:46:03', 'dd/mm/yyyy hh24:mi:ss') I50TDAT, 0.06486 I50UCOST, 'CHC' I50TRNS from dual union all
select 'BACCA004' I50PART, to_date('28/08/2007 15:49:15', 'dd/mm/yyyy hh24:mi:ss') I50TDAT, 0.06328 I50UCOST, 'CHC' I50TRNS from dual union all
select 'BACCA004' I50PART, to_date('30/10/2008 09:22:40', 'dd/mm/yyyy hh24:mi:ss') I50TDAT, 0.06952 I50UCOST, 'CHC' I50TRNS from dual union all
select 'BACCA004' I50PART, to_date('13/01/2009 09:09:07', 'dd/mm/yyyy hh24:mi:ss') I50TDAT, 0.06867 I50UCOST, 'CHC' I50TRNS from dual union all
select 'BACCA005' I50PART, to_date('25/07/2007 08:27:24', 'dd/mm/yyyy hh24:mi:ss') I50TDAT, 0.06715 I50UCOST, 'CHC' I50TRNS from dual union all
select 'BACCA005' I50PART, to_date('10/04/2008 15:45:14', 'dd/mm/yyyy hh24:mi:ss') I50TDAT, 0.06916 I50UCOST, 'CHC' I50TRNS from dual union all
select 'BACCA005' I50PART, to_date('30/10/2008 09:05:17', 'dd/mm/yyyy hh24:mi:ss') I50TDAT, 0.07453 I50UCOST, 'CHC' I50TRNS from dual union all
select 'BACCA005' I50PART, to_date('13/01/2009 09:06:49', 'dd/mm/yyyy hh24:mi:ss') I50TDAT, 0.07275 I50UCOST, 'CHC' I50TRNS from dual)
select I50PART, I50TDAT, I50UCOST, I50TRNS
from (select I50PART, I50TDAT, I50UCOST, I50TRNS, row_number() over (partition by I50PART order by I50TDAT desc) rn
from I50F
where I50TRNS = 'CHC')
where rn <= 2
order by I50PART, I50TDAT desc;
I50PART I50TDAT I50UCOST I50
BACCA001 10/04/2008 16:29:02 .10639 CHC
BACCA001 25/07/2007 08:26:30 .10329 CHC
BACCA003 10/04/2008 13:30:12 .17535 CHC
BACCA003 25/07/2007 08:26:54 .17024 CHC
BACCA004 13/01/2009 09:09:07 .06867 CHC
BACCA004 30/10/2008 09:22:40 .06952 CHC
BACCA005 13/01/2009 09:06:49 .07275 CHC
BACCA005 30/10/2008 09:05:17 .07453 CHC -
How to get the data based on below data-----pls help me...
Hi,
i have the data in my table.......
SET_ID SET_Name Status date user_name
SET974 F698671 I 24/03/2011 10:40:05 TEST1
SET974 F698671 I 24/03/2011 10:40:05 TEST1
SET974 F698671 N 24/03/2011 10:40:05 TEST1
SET974 F698671 I 24/03/2011 10:40:05 TEST1
SET528 A258961 I 22/03/2011 9:40:05 TEST2
SET528 A258961 N 22/03/2011 9:40:05 TEST2
SET528 A258961 I 22/03/2011 9:40:05 TEST2
SET528 A258961 I 22/03/2011 9:40:05 TEST2
SET974 F698671 I 25/03/2011 13:40:05 TEST1
SET974 F698671 N 25/03/2011 13:40:05 TEST1
SET974 F698671 N 25/03/2011 13:40:05 TEST1
SET974 F698671 I 25/03/2011 13:40:05 TEST1
SET974 F698671 I 26/03/2011 15:40:05 TEST5
SET974 F698671 N 26/03/2011 15:40:05 TEST5
SET974 F698671 N 26/03/2011 15:40:05 TEST5
SET974 F698671 I 26/03/2011 15:40:05 TEST5
I want to know each user ,how many sets modified.
based on above input data,my output would be in the following way:
user_name no.of sets upated for single user
TEST1 2
TEST2 1
TEST5 1Based on your sample data, why does TEST1 have a count of 2? From what I can see, the only SET_ID that is associated with TEST1 is SET974 so I would think that you'd want TEST1 to have a count of 1.
If I ignore the data you posted and just look at the text of your requirements, I would guess that you wanted
SELECT user_name, COUNT( DISTINCT set_id ) cnt
FROM some_table
GROUP BY user_nameThis won't give the output you said you wanted based on the sample data you provided, however, for the reason I outlined above.
If you actually do expect to get the output you posted from the sample data you posted, can you explain in a bit more detail why TEST1 should have a value of 2? It would also be helpful to post the CREATE TABLE and INSERT statements rather than just dumping the data. If you provide DDL & DML, we can create the objects locally and verify our solutions rather than guessing based on eyeballing the data.
Justin -
Transfer Forecast data based on Customer information for product and plant
Hi,
This is the scenario.
Our characterstics are Product,Plant and Customers
and for 1 plant and product there may be 5 customers.
My characterstics will be
P1 L1 C1
P1 L1 C2
P1 L1 C3
P1 L1 C3
P1 L1 C4
P1 L1 C5
(P1-Product; L1 for Plant and C1,C2...are customers)
Now forecast data will be different for different customers.
I transfer demand from APO to ECC for PRoduct ,Plant and different customers.
Then in ECC how to check for different customers.
If you go to MD63 you can see for plant and product but not for customers.
This is required as we are running MRP for that product for component planning.
Thanks in Advance
Raghavendra PaiHi Ragvendra,
In ECC we can transfer at material and plant level only and not information of customer. As you need for MRP run may be you can explore possibility of using some badi and get customer no in requirement plan number or some other feilds.
Other option is planning with descriptive chartceristic in APO only. It is not possible to transfer demand with descriptive charcteristics to ECC.
Here you can forcast demand on customer level. Transfer it as PIR with descriptive charcteristics to PPDS where you can plan for this demand.
For information see link http://help.sap.com/saphelp_scm50/helpdata/en/c1/147a375f0dbc7fe10000009b38f8cf/frameset.htm.
If your requirement is to transfer customer information to ECC from DP in standarad it is not possible as far as I know.
Regards,
Siddharth -
To get data based on entry dates..
hi,
In the input parameter there is start date and end date, if the new hire date falls between these two dates then only
Get the details Name, SSN, birth date, status, position in text file.hi
Make the date as select option
Ex. SELECT-OPTIONS: s_budat FOR faglflexa-budat
in select condition
sartdate>= s_budat -low and enddate <= s_budat -high.
I think it will work fine -
Isolating lines of table Data based on maximum date
Post Author: morty
CA Forum: Formula
G'day fellow Crystal Users. Please help me. I have a table that records employees and their salary information. The key field in the table is the Employee's 'Employee Number' however this is not a unique field as each time an employee receives a pay increase a new line of data is created for them. So what I want to be able to do is isolate their most current pay line/information. The obvious field to isolate this data is the 'date of the increase' field. I have tried using the 'maximum' function but cannot seem to get it to do what I want. Can anybody please help me???????Post Author: Jagan
CA Forum: Formula
Group by employee, and use the group selection formula to only get the most recent salary record per employee, i.e.
{salary.date} = maximum({salary.date}, {employee.id})
Maybe you are looking for
-
Slow performance when moving bunch of vector shapes
Hi there, Photoshop CS6 Beta is soo slow in comparison to Photoshop CS5 when moving lots of vector layers. Check the videoa below please: CS6 - http://screencast.com/t/wBOzhTySdSf CS5 - http://screencast.com/t/ab7BDbgNxUYe - GPU Settings Enabled in b
-
Does anyone have a good list of blocked IPs? I have no reason for anyone outside of the US to be connecting to my machines. I'm sick of blocking all these different /8 as they come up trying to hammer my FTP site. I know I can look at the ICANN list,
-
Unable to clear the GR/IR account
Hi friends, My user booked the GRN is 13.03.2010. the entry is Material/Services a/c 1000 To GR/IR a/c 1000 Here Invoice and vendor payment are done in 24.04.2010, payment as cleared. But client wants close the year-end closing 2009-10 . Here
-
HT201407 iphone says could not be activated because the activation server is temporarily unavailable
i tried to activate my iphone but it says that could not be activated because the activation server is temporarily unavailable.
-
HT201210 why wont itunes connect to the istore
why wont my itunes connect to the itunes store