BADI for storage location restriction in IW32

Dear All,
I am working on one scenario in this user has to get the error message :-
1. Whenever he doesn't enter the Storage Location in Component Tab (in IW32) and also he should not be able to save the Maintenance Order.
2. There is ZTABLE (ZTPM058) , if there is no entry of the Storage location in the ZTABLE then also he should get the error.
I have used the BADI BADI_DI_PCS2_1 to do this but the problem is when the user enter the component manually then it works fine , but when he selects the component from List button (it is in the bottom of the component tab screen) , then this BADI doesn't work correctly.
Basically when the user selects component from List  then it should first put data into the component tab and then give the error . but this is not happening.
Please suggest what can be done.
Below is the code that I have  written :-
l_ucomm = sy-ucomm.
if diad_resbd-MENGE is not INITIAL.
  SELECT SINGLE ingpr         "Plant Section
                lgort         "Storage Location
          INTO  (l_ingpr,
                l_lgort)
          FROM  ztpm058
         WHERE  lgort = diad_resbd-lgort
           AND  ingpr = diad_caufvd-ingpr.
  IF sy-subrc <> 0.
if l_ucomm <> 'IMKL'. 
   CONCATENATE 'FOR ITEM NO'        diad_resbd-posnr
               ', COMPONENT'                   diad_resbd-matnr
              'AND PLANNER GROUP'       diad_caufvd-ingpr
             'THERE IS NO STORAGE LOCATION'  diad_resbd-lgort INTO txtmgs SEPARATED BY space.
    clear l_ucomm.
    clear sy-ucomm.
    MESSAGE txtmgs TYPE 'E' .
    elseif l_ucomm = 'IMKL'. (OK CODE when user press List button)
         CONCATENATE 'FOR ITEM NO'       diad_resbd-posnr
                    ', COMPONENT'                   diad_resbd-matnr
                    'AND PLANNER GROUP'      diad_caufvd-ingpr
         'THERE IS NO STORAGE LOCATION'  diad_resbd-lgort
INTO txtmgs SEPARATED BY space.
    clear l_ucomm.
    clear sy-ucomm.
    MESSAGE txtmgs TYPE 'W' .
    endif.
    endif.
    ELSE.
    message 'Please enter the Quantity' type 'W'.
    clear l_ucomm.
    clear sy-ucomm.
    endif.
Thanks and Regards,
Rachit Khanna

Dear Rajesh Kumar Raju
Go to IMG-->Logistics Execution >Shipping> Picking -->Determine Picking Location -->Define Rules for Picking Location Determination.  There you have to assign the MALA rule to your delivery type
Also maintain in OMJ8 and in material master under MRP2 view the default storage location in the field "Prod. stor. location"
thanks
G. Lakshmipathi

Similar Messages

  • Authorization Check for Storage Location

    Hi Experts,
    I have the following requirement :-
    I have Plant : P081 created under Company Code : P110.
    I have got various Storage Locations under this Plant for example
    KT01 - Main Stores
    KT24 - Remote Store.
    The KT24 store is basically a remote location store. I have activated the Authorization for the Storage Location KT24 in the SPRO Settings
    Material Management --> Inventory Management and Physical Inventory --> Authorization Management --> Authorization check for storage location.
    I have maintain the following authorizations for the Object M_MSEG_LGO as follows :-
    1. OBJECT : M_MSEG_LGO.
    >> 2. USER ID : 081Store
    >> 3. PLANT : P081
    >> 4. STORAGE LOCATION : Kt24
    >> 5. ACTIVITY : 01-03
    >> 6. MOVEMENT : 101, 102, 201, 221, 261
    and authorization for T_code MIGO_GR and MIGO_GI . I want to restrict the user for transaction only for this storage location but the system is allowing the user to post GR document for KT01 stores also.
    Can any one suggest a solution or settings that need to be done for the user to be restricted to prepared GR for Storage Location KT24 only.
    Thanks in advance.
    AJ

    Hi,
    You set the authorizations to users with tcode PFCG. To know the reason of deny some access run tcode SU53 after SAP denies the access to some documents / objects.
    Regards,
    Eduardo

  • Storage location restriction

    Dear Experts,
    our client has stroage location like STRM ,WHO4 and users X,Y.User X transfer material from STRM to WH04
    and Y transfer material from WH04 to STRM.while they moving their stock they create annexure 1 and annexure 2 to
    move material,but user X transfering the material WH04 to STRM,without any document,we tried removing authorization
    WH04 for X,but x even can not move material from STRM to WH04.our aim is to restrict user X transferring the material from
    WH04 to any other location.please suggest how to control this,
    Thanks in advance,
    Varun

    Hello Varun,
    Try for authorisation of storage location:
    Materials Management>>>Inventory Management and Physical Inventory>>>Authorization Management>>>Authorization Check for Storage Locations.you can restrict the user to use his storage location only by authorization object assigned to the user role.
    OR
    one simplw solution is , for production people create one storage location.
    now after this assign this storage location in MRP2 view in prosution storage location field.
    As storage location assigned in material master it automatically pick up in process or prodution order as a default here u can
    if required grayed out the column.Due to this user has to issue material from production storage location.
    You can view the similar thread for the same in SDN:
    Material taken from other Storage location
    Hope the information is useful
    Regards,

  • Report for Storage location wise Stock with value..?

    Hi guru's
    Can anybody explain me what is T.code i want to use to get a report for STORAGE LOCATION STOCK  with VALUE..?
    Urgent reply me  ..
    Thanks
    sap-mm

    Sorry Mr chetan,
    I want to see only the stock available in my company with Value and storage location wise..
    Please try to get report for this
    Thanks
    sap-mm

  • System asking for storage location in case of Asset GR,

    dear all,
    In our case  system is asking for Storage Location in case of Asset GR, though PO was account assigned.
    I checked for the screen setting, but not getting any clue where to find that entry to make depressed.
    Pls guide,
    Regards.

    Hi,
    Are u using material code for assets or its a text based purchase, if material code is there (although non valuated / qty managed) it will still require sloc as system needs to store the qty in stock
    Reg
    dheeraj

  • Use of Vendor and Customer in 'Define Shipping Data for Storage Location"

    Under the stock transfer order configuration, there is a IMG step <b>"Define Shipping Data for Storage Location".</b>
    In this at storage location level, we can assign, sales org/distribution channel, division and VENDOR and CUSTOMER to storage location.
    The customer number is used a sold-to-party in outbound deliveries.
    <b>But I am not able to figure out what's the use of VENDOR number we are specifying in this step.</b>
    If I am assiging the VENDOR Number here to every storage location, then when I am creating cross-company code Stock transport order, which vendor code I will select the one assigned to PLANT or one Assigned to Storage location.
    <b>Also I need to know what vendor account group I will use for creating this storage location vendor.</b>  I have more than one storage locations) under one plant. Soif I used account group as "0007" plant, SAP doesn't allow me to assigne one plant code to 2 vendors and in vendor master on 'additional purchasing data' screen I am not seeing storage location field, it has only 'PLANT' field.
    <b>So I need to know-
    1. Which account group to use for creating storage location vendor
    2. What's the ultimaye use of this vendor code
    3. What vendor # I will use while creating cross-company PO (one for plant or one for storage location.</b>
    Thanks

    Hi,
    Define Shipping Data
    Here in this step you maintain the customer number of the receiving plant. This customer number is used in SD shipping processing to identify the goods recipient (ship-to party) if stock transfer to be carried out with an SD delivery
    A goods receipt can be planned in the receiving plant.
    You can enter a vendor (transport vendor) in the stock transport order
    In IMG step "Define Shipping Data for Storage Location".
    You can assign sales org/distribution channel, division and VENDOR and CUSTOMER to storage location through Plant only.Means this Vendor is created for entering in the STO .This vendor is created for the the Plant (Supplying Plant)so as u can create STO.
    Rewards If usful
    Regards
    Sanjay L

  • HU Configuration for Storage Location

    Hi everyone.
    In the following point of config, there is something I do not understand.
    I hope somebody can explain it to me.
    HU Requirement for Storage Locations and Default Values for Deliveries
    Are the Vendor and Customer needed in this table?
    If they are, what purpose do they serve? What are they needed for?
    And again, if they are, do they represent the Plant? or what?
    Should they be created with special characteristics?
    I know a lot of questions, But I do not understand.....
    Thanks,
    Alain

    Hello Alain,
    When you are making the storage location is HU managed, and when you try to execute any IM transactions like stock transfer, transfer posting, system doesn't directly post a material document unlike in regular non HU managed locations.
    For example if you try to execute MB1B-311 from HU managed location to non HU location, system tries to create an outbound delivery document. And to create this outbound delivery document you need a customer and this is the place where system gets that customer information. Same is the case for vendor in inbound delivery.
    And it doesn't require to create deliveries all the time if you want to execute these inventory transactions. VLMOVE transaction can be used to posting material document without deliveries.. But not all business scenarios will use VLMOVE as it has its own limitations.
    Regards
    Gopal

  • Negative stock  for storage location M7 021

    Hello
    I use negative stock for some materials
    When I want to post document in MIGO - 551 scrapping, I have error message M7 021: Deficit of BA Unrestricted-use 1.100 EA:   24000641 XXXX 9999 YYYYYYY
    This is ERROR. When I change storage location from 9999 to 0002 message have status WARNING.
    I set - allowed negative stock in material master data MM02 and for plant in WB02
    Where should I set "allowed negative stock" for storage location, because I need warning for location 0002?
    Could You help me?
    Thank You in advance
    Arek

    Go to SPRO>MM>IM>Goods Issue/Transfer posting>Allow negitive stock allowed for plant and then chose the plant and then go for the storage location --> mark the same.
    If use ful award points

  • Table name or report to download materials for storage location

    Hi ,
    Please let me know table name or report or tcode to download material for storage location . I know MARD only. Apart from that table any other please let me knw
    Thanks in advance
    Smitha

    Hello,
    For Material , Plant and storage location report, in SAP Std reports are available.
    1)MC.6
    2)MC.9
    3)MB5b
    4)MB52
    or else get directly from table MARD through SE16 tcode.
    Regards
    Mahesh Naik

  • Problem in Address update for storage location via LSMW

    I am trying to update the address of storage location thru LSMW,
    Normally when i run OX09 i get the "dialogue structure' in LHS panel but when I do the recording of OX09 in LSMW, I am not getting the "Dialogue structure" LHS panel & hence I can't go to the 'Addressees for storage location'
    How to get the ""Dialogue structure" in LHS while recording in LSMW so that I can update the address also.
    Currently my recording only takes me to the create storage location & no LHS 'dialogue structure'  for 'Addressees for storage location'
    Please give the suggestions as I its on urgent for me to update 1000 storage location.

    Dearrrrrrr Prasoooon,
    U got it Right Again!!!!!
    Thank you so much.
    I resolved with above Note & now i can happily go on leave from tomorrow.
    Salute to you!!!!!!!!

  • Table for Storage location name..

    Hi frnds,
    I have a storage location number.. Now how do i find the name or Description for that?
    How to find the table? ,, If anybody knows the table name plz let me know..
    Thank you.
    Sree.

    Hi,
       CHeck Table MARD for storage Location
    Regards,
    Prashant

  • Classification System for Storage location

    Hello,
    I would like to know if you can apply the classification system (as we know it well from the material master), to classify the storage location configuration. I need this for a client who wants to analyze his information system with the possibility to drilldown the characterics of his storage locations. But to do this, he first would have to apply the classification system to these storage locations, but I can not figure out if it is possible, and where to customize it.
    Thank you in advance for your help,
    Dominik Ley
    DTI Consultores
    Chile

    yk,
    perhaps it is even some kind of weird, but for 2 reasons I dared to make the question:
    - Classification system is a cross-application component (Material Management, Project System, etc.), so why not for something like storage location.
    - For Plants you DO HAVE this classification. Go to CL02 and have a look on matchcode of 'Class type' field. So, my idea was to check if there was something similar for storage location.
    If you do have any other idea, or anyone else, I appreciate a lot your help.
    Regards,
    Dominik Ley

  • Table for storage location addresses

    Hi
    I am trying to find the table where addresses for storage locations are found. I have found the storage locations in T001L and the addresses in ADRC, but cannot find the link between these tables.
    In which table can I find the link between storage locations and addresses?
    Any help is greatly appreciated.
    Regards

    Hi,
    check TWLAD table.
    Regards,
    Chandra

  • MRP Relevance for Storage Location

    All SAP Gurus,
    In SPRO where we need to maintain MRP Relevance for Storage Location?
    Regards,

    Dear,
    Check transaction OMIR - Storage location - MRP relevance.
    In detail:
    To control whether a particular storage location will be included or excluded from the MRP run.  (MD02/MD41).
    To exclude it from MRP run follow the steps:-
    OMIR - Define storage location MRP per plant
    Put the MRP ind. as.         1 - storage location stock excluded for MRP
    To include it from MRP run:-
    OMIR - Define storage location MRP per plant
    Put the MRP ind. as.      space - storage location stock also planned at plant level and save it
    Next go to transaction MM01 - tick only view MRP 2
    Key in Plant and Storage Location
    Look at the Storage Location MRP section
    change the SLoc MRP indicator to space  and save it
    MMD1 - Create MRP Profile - MRP profile is a useful entry aid and makes it easier to manage MRP data.
    You define which fields are filled with values when MRP data is entered in the material master record, which of these values can be overwritten and which not.   You use the information stored in a profile is standard information that is needed again and again in similar constellations when material master records are maintained.
    Regards,
    Syed Hussain.
    Edited by: Syed Hussain on Sep 20, 2008 12:51 PM

  • Validation for storage location

    Greetings to Experts!!
    I am looking for following two validations;
    1- stock outward movement from a particular storage location (say ABC ) could only be possible via 351.
    2- 351 movement type could only be used for storage location ABC
    Plz Help,
    Regards,
    M. Tayyab Aslam

    For the first one, IN OMJJ, for the movement type , tick The storage location automatic option. If the stor loc in maintained in the material master, then that will be picked automatically..
    For the second , I don find any possiblilty
    karthick

Maybe you are looking for

  • Adobe flash player stopped working 10.5.8.. can not get it to work anymore

    My flash player has not worked for 2 days, i can view some things on Youtube but with no sound so i tried to update my flash player and it doesn't supprt my mac os x version 10.5.8... anyone know what i can do next... Spent over a thousand euro on th

  • Need some help styling datagrid...

    Hi, I have added a datagrid to my flex application and I need to give it a specific style but I can't get it to work. I need to remove the rollover color of the datagrid column headers. I've trawled through the flex forumns and website but so far I'v

  • Best practices to configure files to display and play in order?

    I'm looking for best practices to get saved recordings (songs and business trainings) on my PC correctly configured so they will show up correctly (artist, song title, track number) and play incorrect order. I have lots of MP3 files (and other format

  • Create Content in Portal SneakPreview installation

    Hello, I have got a huge starting problem! I have just started with SAP and my first aim is to try out the Enterprise Portal. For this purpose I have installed the SAP NetWeaver Sneak Preview including the SAP Web Application Server, the SAP NetWeave

  • Online Backup Failed with error-BR0268E Asynchronous execution of program..

    Hi, We are using DB13 for Online backup.But from few days it failing with below error. BR0268E Asynchronous execution of program interrupted, exit status: c0000094 BR0267E Asynchronous execution of program failed BR0278E Command output of 'F:\usr\sap