Delivery date calculation based on route in VA02

Hi.
I am unable to find the code for the calculation of dates in schedule lines in VA02. For plant 0201 the delivery date in schedule lines is coming wrong. I think it is not getting calculated according to the route. In addition, it is not taking route from APO but taking it from R3. I have done the debugging several times and looked into the program SAPMV45A also but still could not find the code for the calculation. Can you please guide me on this?

Hi,
Please check for Implementation of User Exits :
MV45AFZ4
MV45AFZA
MV45AFZB
MV45AFZC
MV45AFZD
MV45AFZF
MV45AFZH
MV45AFZU
MV45AFZZ
Thanks & Regards
Suresh Nair

Similar Messages

  • How is delivery date calculated

    How can anyone please explain how delivery date is calculated using forward and backward scheduling
    I want to have it broken down into the following steps
    for eg for delivery date calculation following dates are used
    Material Availabilty Date
    Material Staging Date
    Pick/pack time
    Transportation PLanning date
    Loading date
    Goods issue date
    Transit Date
    Delivery Date
    Can some one please give me an example and explain wht these dates are
    for eg customer needs delivery date on  11/20/2008
    how would the system cacluate whether it can meet the delivery date using backward scheduling
    and if it doesnt meet how does the system do the forward scheduling
    also i am not clear with the following dates
    material avaialibilty date
    material staging date
    transportation date
    can some one please explain me all this in detail
    Also i have another question at the sales order creation when is shipping point and route determined
    coz based on the ATP check only material avaialabilty date is determined and if we have a bacjground job running every 1 hours for atp then immediately when we create a sales order is a route and shipping point determined (just before we save the sales order)
    Let me be more clear
    Suppose customer representative recevies a order on the phone
    he enters sold to party, ship to party ,PO number,delivery date and material number and then hits enter
    so at tht time the shipping point and route is determined ?
    also when an atp check runs and if the delivery date is not met then the system will propose a new delivery date but if we have a different route configured say for eg overnight so we can meet the delivery date and we want to change this route to overnight what must we do?
    should we change the shipping condition in the header?
    I am not very sure about the process can you please also explain me this in detail?
    Thanks

    Hi there,
    When a sales order is logged & the user enters the requested delivery date, system 1st does the backward scheduling date. Pla note that the factory calender mentioned in the shipping point & route plays a crutial role in defining the working days & confirmed delivery date.
    For eg:  Customer has raised an order on 11/15 & requests delivery on 11/20/2008.
    the following times are important in delivery scheduling.
    Transit time: maintained in route
    Loading time maintained in the shipping point
    Transportation planing time maintained in the transportation planning point.
    pick pack time maintained in the shipping point.
    Material availability time maintained in MM02 --> MRP screens. This is the time that the material can be manufactured (for inhouse producted items) or external processing time (for externallly procured materials like TAS items).
    From the requested delivery date 11/20 system does the backward scheduling & determines the following dates:
    Goods issue date, loading date, pick pack date, transportation planning date & material availability date.
    Time between:
    goods issue date - reqested delivery date: transit time
    Goods issue date - loading date: loading time
    transportation planning date - pick pack date: picking pack time
    Material availability date - transportation date: transportation planning time.
    Consider that the factory calender has all days of the week as working dates (to make it simple to explain). Also transit time is 3 days, loading time is 1 day,pick pack time is 1 day, material availability time is 3 days.
    From 11/20 ussing backward scheduling system determines the following dates:
    Goods issue date: 11/17
    Loading date: 11/16
    Pick pack date: 11/15
    System will check if material is available on the 11/15 to start pick / pack. If it is available then system will confirm the reqested delivery date. Else it will check when the material is available. For eg basing on the MRP settings mnaterial is available only on 11/18. So from 18th system does forward scheduling & redetermines all the dates. So pick / pack date is 11/18. Loading date is 11/19, goods issue date is 11/20 & possible delivery date is 11/23. So system will confirm the delivery date on 11/23. This is when complete delivery is required. If partial delivery is allowed, then system will check how much quantity is available on 11/15. Accordingly it will give 2 delivery dates.
    In the above example include teh factory calender which will have 5 day week with Fri & Sat as holidays. Accordingly dates will change.
    Here replenishment lead time also plays an imp role. Pls refer http://help.sap.com/erp2005_ehp_03/helpdata/EN/6b/2785347860ea35e10000009b38f83b/frameset.htm for further information
    Regards,
    Sivanand

  • Schedule Line Delivery Date Calculation with Transportation Scheduling

    Hi All,
    We are currently running into a problem where our Sales Order Schedule Line delivery dates are being pushed out too far into the future - because of the Calendar being used to determine the transit time.
    We have 'Delivery Scheduling' and 'Transportation Scheduling' activated for our Sales Document type
    We have Routes that are configured with a 'Transit Time' and a 'Factory Calendar'
    Order Scenario:
    'Factory Calendar' assigned to our 'Route' is setup with only one 'Workday' in a given week e.g. Wednesday
    Our 'Route' has a Transit Time of 2 days
    We create a Sales Order on Monday for a Material that is available in our Plant
    The 'Goods Issue' date is being determined correctly for the next Workday - being Wednesday
    The 'Delivery Date' is extending out over 15 days (2 Wednesdays into the future) - since it is working on 'Calendar Days' and not 'Actual Days'
    Does anyone know of a way (config or other) to only influence the 'Goods Issue' date with the 'Factory Calendar' assigned to the Route, and have the 'Delivery Date' calculated using the Transit Time on the Route and 'Actual Days' rather than Calendar days?
    All help greatly appreciated.
    Thanks,
    Ravelle<i></i>

    Hi Pathik,
    Thanks for your reply.  I have already maintained the Calendars I'm using for this business process in <SCAL> - same as <OY05>. 
    The problem I'm having though is that by assigning a Calendar directly to my route (which I doing to influence the goods issue date - using a 1 Working Day Calendar) it is also taking precedence in determining the Transit time - which in this case I don't want, as I want my Transit time to be determined using a 5 Working Day Calendar.
    I don't think this problem has a config option as a work around...I think the only possibility in this case is a development to achieve the results we need.
    Thanks,
    Ravelle

  • PR delivery date calculation for TAB orders

    Hi All,
    1) The PR which is created via TAB item in the sales order - the delivery date for such PRs is equal to the delivery date in the sales order. This is happening only for TAB orders without BOM explosion in the sales order.
    2)In BOM exploded sales order - (meaning the parent item is entered in the sales order with item category TAP. ) -The sub components of this parent item is auto populate in the sales order. If any one of these sub components have item category TAB...then it creates a PR which has the delivery date equal to the "Planned delivery time" in the info record.
    Can anybody please explain why the PR default delivery date is different in the two cases explained above. Both are TAB items...the only difference is one is a stand alone TAB item and the other is via BOM explosion.
    Your help will be highly appreciated.
    Thanks
    Ashok

    Hi Sasy
    Delivery date calculation for MRP generated PR will follow the below settings
    1) Purchasing processing time in the Plant parameters in the customization and is calculated based on the Factory calendar days.
    2) Planned delivery time maintained in PIR and is calculated based on Normal calendar days
    3)GR Processing time Maintained in Material master record, calculated based on Factory calender.
    If you add up in the following sequence then you will get the exact delivery date.
    Purchasing Processing time + Plnd delivery time + GR processing time.
    Hope it will solve your  issue.
    Thanks / Karthik

  • No delivery date calculation required

    Hi,
    Situation:
    Our US sales organization works with a non SAP ecommerce tool for sales of all materials. Every night (European time) a job is scheduled to send over the information about created orders and deliveries. As such orders get created in SAP.
    Most often the delivery for these orders already occurred so they just want to deliver them out of SAP once the orders are created there. They do not want SAP to calculate the earliest delivery date based on ATP logic and routing because then they have to constantly set the delivery date in future during delivery creation.
    Our US colleagues only mind of the stock levels which they constantly (every 10 minutes) update to their web based tool and which they want to be accurate all the time.
    My idea was to set the availability check for all materials in the US sales org to "KP - Do not check". But then I still have to deal with the route determination. Would it be wise to set the number of days to 0 for each case?
    Or can I somehow "switch off" routing for US delivered customers?
    What would be the best way to make sure the proposed delivery date in the schedule lines for every material has the date the order was created? Except for ATP logic and route determination are there any other settings I have to consider?
    Best regards,
    Geert

    Fix the root problem.  Give them a website that accesses SAP in real time and obviate the need for any synchronizations.  I am willing to bet that ATP and Deliveries are not the only synchronization issues.  What about pricing (more than likely now maintained in two places), relationship between soldtos and shiptos, two freight calculating programs, two tax calculating programs etc. etc.
    I know that this isn't a very helpful answer to you in the short term.  However, I encounter this problem on a daily basis and have come to learn that it's not an ATP issue.  It's an IT versus Business issue.  How could a disconnected website have been created in the first place?  That's the question that your business should really be asking.
    Sam

  • Function module SD_SCHEDULING: delivery date calculation factory calendar

    Hi,
    When I create or change a sales order, system calculates the delivery time and date (ETDAT) using transit duration and factory calendar. Currently factory calendar says that transportation leaves every Monday, Wednesday and Friday. Unfortunately, function module SD_SCHEDULING calculates the delivery date using factory calendar dates, i.e. <b>NOT</b> using working dates.
    Function module reads the factory calendar from table TVRO (Routes) and field SPFBK (Factory calendar key) in subroutine GET_CUSTOMIZING, and saves factory calendar id in CS_SCHEDDU-TRANSIT_FC. The calculation itself is done later in function module DATE_CONVERT_TO_FACTORYDATE.
    For example, if transit duration is 3 working days, function module calculates the delivery date using Monday (first day), Wednesday (second day) and Friday (third day). Thus, the result is Friday, which is wrong. Result should be of course Wednesday (Monday first day, Tuesday second day and Wednesday third day).
    I'd like to use working days instead of calendar days. I am planning to recalculate the delivery date in some user exit, but before I start coding, I'd like to hear your opinion: <i>Is it possible to use working days instead of calendar days when calculating delivery date?</i> (I believe it must be, since my case is very normal). If it is, I assume that this can be achieved with IMG, but how and where?
    I am using SAP R/3 Enterprise.
    Regards,
    Jarmo Tuominen

    Hi jarmo,
    1. DATE_CHECK_WORKINGDAY
       Probably this FM may be useful to u.
    2.
    CALL FUNCTION 'DATE_CHECK_WORKINGDAY'
            EXPORTING
              date                       = d
              factory_calendar_id        = '01'
              message_type               = 'I'
            EXCEPTIONS
              date_after_range           = 1
              date_before_range          = 2
              date_invalid               = 3
              date_no_workingday         = 4
              factory_calendar_not_found = 5
              message_type_invalid       = 6
              OTHERS                     = 7.
    regards,
    amit m.

  • Delivery date calculation in auto scheduling

    Dear All,
    We have maintained planned delivery time , gr processing time in mm master as well infor records.
    We are running MRP and auto scheduling and updating schedule lines through MRP.
    System updating schedule lines and the delivery date also. what is calculation of delivery date in this case ?
    also system updating 3 lines with different delivery date ..why ? why not one line ?
    vijay

    no solution.

  • Delivery dates not affected after route determination

    The dates found on the shipping tab in delivery header are not affected after a route determination.
    In sales order, if route is changed, the dates are affected.
    In delivery, the route is re-determined at delivery creation, but if route transit time is different the delivery dates are not affected. It retains the sales order dates.
    Need system to change dates according to new route.
    Where is this set?

    Hi,
    Transit Time and Transportation Lead time comes from Route while Pick/Pack time and Loading time comes from Shipping point.
    May be in your case, while re-determination of route, just check if the time is enough to affect the date i.e. more than 24 hrs or so
    Hope you got it what I intend to communicate
    Regards
    SD

  • Date calculations based on working days

    I need to add date calculations to a worksheet to show the time elapsed between two actions.
    Just a straightforward subtraction works fine, but what I really need to be able to do is calculate the number of working days between the two point (as something taking 5 days over Christmas with the 2 bank holidays is different equivalent to something taking 3 days in a normal week)
    At the moment I'm exporting the data into excel for analysis of this, but would really like to be able to do it in Disco so that the end users can go straight to the report using viewer, rather than having to do the conversion for them.
    Is this possible?
    Cheers

    Hi,
    Every thing is possible, the Q is how complicated is it....
    My suggestion is to create a table with all the dates of the non-working days for ex:
    create a table with all the MON-THURSDAYS, union to this table the holidays you know of such as christmas and so on.
    After getting this table you can create a function that returns the number of working days between 1 date to another by subtracting the days exists in this table.
    I started with that, you are more then welcome to get ahead with it and let us know what happened...
    create table holiday
    D_date date,
    d_day varchar2(20)
    create or replace procedure holiday_proc is
    d_date date;
    begin
    d_date := trunc(sysdate);
    while d_date<'01-jan-2010'
    loop
    if to_char(trunc(d_date),'Day') not in ('Saturday ','Sunday ') then
    INSERT INTO Holiday (d_date,d_day)
    (select trunc(d_date),to_char(trunc(d_date),'Day') from dual);
    end if;
    d_date := d_date+1;
    end loop;
    commit;
    end holiday_proc;

  • Automatic delivery date change based on logistics calendar

    Dear Experts,
    I have a certain plant for which i have 5 days working & for the rest i have all days working .
    My requirement is that the system should find out & change the delivery date in PO automatically , if the delivery date falls on a holiday .
    I have assigned the 5 days a week calendar to the requitred plant & also i am getting the warning message ME080 in the PO  , but the system is NOT changing the delivery date .
    Please suggest what needs to be done in order to have the system to change the delivery  date automatically ?
    Thanks & regards
    Anis

    hi
    check is there any user exit or BAPI can be implemeted in your system with the logic you want.

  • ATP check in va01 should consider BOM components delivery days for delivery date calculations of header material

    Hi All,
    My requirement is for ATP check in sales order,
    I am creating sales order for header material(FG) using strategy group 40.
    Its BOM consist 3-4 ROH, each ROH is assigned scheduling agreement.
    EX: I am creating order on todays date for FG
    IN-HOUSE production time = 5days, GR processing time = 1days
    transportation time = 5days.
    ROH 1= 1week, ROH 2= 2week, ROH 3 = 3weeks
    Now After MRP run for FG's, planned order will be created for deficit stock.
    now while doing ATP check in sales order system calculates delivery date = In-house production time + GR processing time + Transportation time.
    But components for manufacturing FG's are not considered .
    System should throw delivery date = In-house production time + GR processing time + Transportation time + components(ROH) delivery time (whichever is higher : As without this order delivery date is useless).
    Experts Please help.

    Pratik,
    In R/3 ATP check carried at one level material only for which you are entering schedule/delivery lines in sales order.
    If you are talking about cumulative availability check then please consider APO GATP.
    There is workaround for your requirement by considering Assemble to Order Strategies.
    Please go through below link Sales order availability check considering the ROH stock/procurement time
    Br
    KK

  • Promised Date Calculation based on Need by Date and Transit Time

    Hi,
    I have created PO with NBD as D25 (Day 25) and approved it. This means that i need the goods to be at my premisis by D25.
    Now the requirement is
    Promised date in my PO should be calculated to D25 - Transit Time. So that supplier will be notified D25-Transit time.
    Or Is there any workaround to overcome this.
    Thanks,
    Jey

    Jey-SCMFG wrote:
    Hi,
    I have created PO with NBD as D25 (Day 25) and approved it. This means that i need the goods to be at my premisis by D25.
    Now the requirement is
    Promised date in my PO should be calculated to D25 - Transit Time. So that supplier will be notified D25-Transit time.
    Or Is there any workaround to overcome this.
    Thanks,
    JeyHi Jey,
    Where you are capturing your lead time. You can do it in item master.
    Once it is there, write a personalization to calculate the promised date and update the field.
    Thanks,
    PS.

  • Retirement Date Calculation based on Date Of Birth

    Hi All,
    We have 11.1.2.2 PSPB Application where we have requirement to calculate "Retirement date" (in the format dd/mm/yyyy) based on employee's "Date Of Birth", for which i tried with @DateRoll function, but no luck. For time being we tried "Retirement Year" which was successful.
    "Retirement Year"=@INT ("Date Of Birth"/10000)+60;
    For Example: If Employee's Date of Birth is 7/11/1946 thru above script i got 2006 as his "Retirement Year", now i need "Retirement Date" as 6/11/2006 which im not getting. I tried in all ways like:
    1) "Retirement Date"=@DateRoll ("Date Of Birth",DP_YEAR,1); got output as 31/03/5127 for "Date Of Birth" 01/01/1975
    2)"Retirement Date"= @FORMATDATE ("yyyyddmm",@DateRoll ("Date Of Birth",DP_YEAR,1)); no luck.
    3)"Retirement Date"=@DATEDIFF (@Today(),"Date Of Birth",DP_YEAR)); no luck.
    Also all the Date functions like @DateRoll,@FromatDate,@DateDiff etc returns number representing the date between January 1, 1970 and Dec 31, 2037, is that true? If yes, what functions needs to be used for  "Date of Birth" above the range.
    Please suggest ASAP.
    Thanks in advance.
    Regards,
    Sahi

    If anyone's interested, I found a solution
    if (DropDownGuarantee.rawValue eq "1" and DteStart.rawValue ne null) then
    Num2Date(Date2Num(DteStart.formattedValue, "M/D/YYYY") + 30, "M/D/YYYY")else
    if (DropDownGuarantee.rawValue eq "2" and DteStart.rawValue ne null) then
    Num2Date(Date2Num(DteStart.formattedValue, "M/D/YYYY") + 30, "M/D/YYYY")else
    if (DropDownGuarantee.rawValue eq "3" and DteStart.rawValue ne null) then
    Num2Date(Date2Num(DteStart.formattedValue, "M/D/YYYY") + 60, "M/D/YYYY")else
    if (DropDownGuarantee.rawValue eq "4" and DteStart.rawValue ne null) then
    Num2Date(Date2Num(DteStart.formattedValue, "M/D/YYYY") + 60, "M/D/YYYY")else
    if (DropDownGuarantee.rawValue eq "5" and DteStart.rawValue ne null) then
    Num2Date(Date2Num(DteStart.formattedValue, "M/D/YYYY") + 60, "M/D/YYYY")else
    if (DropDownGuarantee.rawValue eq "6" and DteStart.rawValue ne null) then
    Num2Date(Date2Num(DteStart.formattedValue, "M/D/YYYY") + 90, "M/D/YYYY")else
    if (DropDownGuarantee.rawValue eq "7" and DteStart.rawValue ne null) then
    Num2Date(Date2Num(DteStart.formattedValue, "M/D/YYYY") + 90, "M/D/YYYY")else
    if (DropDownGuarantee.rawValue eq "8" and DteStart.rawValue ne null) then
    Num2Date(Date2Num(DteStart.formattedValue, "M/D/YYYY") + 90, "M/D/YYYY")else
    if (DropDownGuarantee.rawValue eq "0" and DteStart.rawValue ne null) then
    Num2Date(Date2Num(DteStart.formattedValue, "M/D/YYYY"), "M/D/YYYY")else
    if (DropDownGuarantee.rawValue eq "9" and DteStart.rawValue ne null) then
    "enter expiration date"
    Marlene

  • Help with date calculation based on office hours

    Hi,
    could you guys point me which way should I think of in PL/SQL, or maybe SQL to calculate a date using not 24 hours day, but office hours.
    Let me give you an example
    Office hours are between 9am till 5pm
    I receive a case - registration time - 14.03.2013 4pm, and I'm supposed to calculate the Due date, let's say Registration time + 10hours.
    Normaly I would do "registration time" + 10hours, but I can't. I cannot use 24 hours window for the calculation, but 9am - 5pm window.
    So the "Due timestamp" would be = "16.3.2013 10am". Which is : 1 hour from 14.03. + 8hours from 15.3. + 1 hour from 16.3.
    Thanks for any ideas.

    Hi,
    A user-defined function would be very handy for that. Foir example
    add_office_hours ( in_start_date DATE
                     , in_num_hours  NUMBER
    RETURN DATE
    DETERMINISTIC ...First, copy in_start_date to a local variable, start_date, and check if start_date is within office hours. If not, change it to the beginning of the next business day.
    Add in_num_hours to start_date. Is the result before 5pm on the same day?
    If so, the function is finished. Return that date.
    If not, find how much past 5pm the result is, and recurse (that is, have the function call itself with a new, later in_start_date and a new, smaller in_num_hours). If you prefer, you can use a loop instead of recursion.
    How do you treat weekend and holidays?
    Would you want to call the function with a negative number of hours?
    If you'd like help. post your best attempt.
    Post CREATE TABLE and INSERT statements for a table that you use for testing. The table should have start_date, num_hours and correct_result_date columns.
    Always say which version of Oracle you're using (e.g. 11.2.0.3.0).
    See the forum FAQ {message:id=9360002}

  • Delivery Date in SO not calculated with Route Transit Time

    Hello Experts,
    We are not able to calculate the delivery date in Sales Orders based on the Route transit time.We are using the Transportation group from Material master , Shipping condition from sold to Party , and Receiving issuing plants and zones .
    One thing I notices is if we don't use the Transportation group in the material master , then the delivery date calculated based on transit time.Not sure not why its not working with using Trans group in Mat master
    Please advise.
    Thanks in advance

    Hi,
    Kindly do not post same questions twice
    HI,
    For delivery scheduling enter time
    IMG >> SD >> Basic functions >> delivery scheduling and transportation >> maintain duration
    Maintain here route, pick/pack & loading time
    For in house production maintain time in material master in MRP view
    Then now system will take in account what is production time + pick/pack + load time and then will schedule
    Kapil

Maybe you are looking for

  • Itunes upgrade

    I upgraded to the 7.2 whatever ******** and now my itunes wont open. Installation went fine, quicktime will still open but it shows no errors when itunes doesnt open. I have nortons if that means anything. I just got an ipod and now i can't put music

  • PO Release characteristics

    Dear All, What all release characteristics can be used for PO. Can Purchasing Organization be used as release characteristic. Regards, Vikas

  • [SOLVED] wine arial font only bold and italic

    I have installed office 2003 in wine. Some one send me a document in arial regular font. It looks fine in winxp, but when I open with the word by wine the all the arial font looks bold and italic. I have also tried with winetricks corefonts but nothi

  • Syncing between my MacBook, iPhone & iPad.

    My Contacts don't seem to be syncing any longer between my MacBook, iPad & iPhone. I've just updated to iOS 7 - could this be part of the problem?? Help!

  • Schedule runtime scenario - RTW Availibilty-time Planning

    Hello all- Is there documentation on RTW Availibilty-time Planning? I want to learn options on daily, weekly scheduling of ID scenarios using RTW Availibilty-time Planning. (similar to SM36 TCODE in SAP) How to schedule outbound IDOC and HTTP scenari