Product Category - Overriding the defaults

I have implemented the BADI to map the Product Category during the external catalog shopping cart creation.
I have the mapping Ztables.
If the mapping is available, all is working good.
However if the mapping is not available, I have to pass the error message about missing mapping.
The error message is working as well but the product category is getting defaulted to the standard category of the User.
I dont want to set it to the standard category.
Any clue?
SRM Functional says there is config to default and they dont want to change it.
How can I override this config?
Thanks in advance.

I am using the David Barber's workaround as specified above.
In the BAD, I am calling the FM: BBP_PD_SC_GETDETAIL and it gives me the SC details.
After validations, I am updating the ET_MESSAGES.
The error messages are displayed if the dummy product group is used but the SC is getting saved inspite of errors.
Any idea?
  I_OBJECT_ID                      =
  I_ATTACH_WITH_DOC                = ' '
  I_WITH_ITEMDATA                  = 'X'
  I_ITEM_SORTED_BY_HIERARCHY       =
  I_WITHOUT_HEADER_TOTALS          =
  I_READ_FROM_ARCHIVE              = ' '
IMPORTING
  E_HEADER                         =
  EV_IS_PD                         =
  ET_ATTACH                        =
  E_ACCOUNT                        =
  E_PARTNER                        =
  E_CONFIRM                        =
  E_LONGTEXT                       =
  E_LIMIT                          =
  E_ORGDATA                        =
  E_TAX                            =
  E_PRIDOC                         =
  E_HCF                            =
  E_ICF                            =
  E_ACTVAL                         =
  E_ACC_ACTVAL                     =
  E_HEADER_REL                     =
  E_ITMLIM_REL                     =
  E_STATUS                         =
   wa_msg-MESSAGE      = 'TESTING'.
   move-corresponding wa_msg to et_messages.
CALL FUNCTION 'BBP_PD_SC_GETDETAIL'
  EXPORTING
    I_GUID                           = IV_DOC_GUID
  TABLES
    E_ITEM                           = i_item
    E_MESSAGES                       = i_msg
loop at i_item into wa_item.
if wa_item-CATEGORY_ID = 'M0156'.
    wa_msg-MSGTY        = 'E'.
    wa_msg-MSGID        = 'BBPWS'.
    wa_msg-MSGNO        = '029'.
    append wa_msg to et_messages.
endif.
Any help would be appretiated.
Edited by: Pranu Pranu on Dec 8, 2010 5:27 PM

Similar Messages

  • Can I override the default ReadObjectQuery for an entity and specify my own call

    Hi,
    I am trying to override the default ReadObjectQuery and the ReadAllQuery for an entity and supply my own call.The entities have to be read from the database using a StoredProcedure.I tried doing something like
    Descriptor desc=evt.getSession().getDescriptor(Configuration.class);
    desc.getQueryManager().setReadObjectQuery(new ReadObjectQuery());
    StoredProcedureCall call = new StoredProcedureCall();
    call.setProcedureName("CONFIGSVC");
    call.addUnamedArgument("CATEGORY");
    call.addUnamedArgument("CFGKEY");
    call.addUnamedArgument("VALUE");
    desc.getQueryManager().getReadObjectQuery().setCall(call1);
    desc.getQueryManager().getReadObjectQuery().addArgument("CATEGORY");
    desc.getQueryManager().getReadObjectQuery().addArgument("CFGKEY");
    desc.getQueryManager().getReadObjectQuery().addArgument("VALUE");
    When I try to execute the query
    ExpressionBuilder builder = new ExpressionBuilder();
    Expression expr = (builder.getField("category").equal("GOESVC.GETTDEV")).and(
              new ExpressionBuilder().getField("configKey").equal("GOESVC.REQ")).and(
              new ExpressionBuilder().getField("value").equal("$ENV.$ORIGIN.GOESVC.REQ"));
    ReadObjectQuery query = new ReadObjectQuery(Configuration.class, expr);
    session.executeQuery(query);
    I can see in the log that it completely ignores the call I set and tries to execute using the default call and that too with incorrect mappings between the "entity" field names and the actual database field names.
    2002.11.01 08:50:52.640--ClientSession(8218801)--Thread[main,5,main]--#executeQuery(ReadObjectQuery(com.fmrco.gett.toplink.Configuration))
    2002.11.01 08:50:52.750--ServerSession(7721862)--Thread[main,5,main]--Connection(5230193)--SELECT CFGKEY, CATEGORY, VALUE FROM CONFIG_ETT WHERE (((category = 'GOESVC.GETTDEV') AND (configKey = 'GOESVC.REQ')) AND (value = '$ENV.$ORIGIN.GOESVC.REQ'))
    2002.11.01 08:50:53.375--ClientSession(8218801)--Thread[main,5,main]--EXCEPTION [TOPLINK-4002] (TopLink - 9.0.3 with StoredProcedureCall patch [email protected] 28/10/2002 (Build 423)): oracle.toplink.exceptions.DatabaseException
    EXCEPTION DESCRIPTION: java.sql.SQLException: [SQL0206] Column CONFIGKEY not in specified tables.
    INTERNAL EXCEPTION: java.sql.SQLException: [SQL0206] Column CONFIGKEY not in specified tables.
    How to I solve this issue?
    Thanks,
    Harini

    Hi,
    The "ReadObjectQuery" in a descriptor's query manager can only be used to change the primary key read query. It will be used only for a ReadObjectQuery that either has a selection key, selection object, or an expression that exactly matches the primary key.
    If you have a non-primary key query that you want to use, you can add it as a named query to the descriptor's query manager.
    I'm not sure of the primary key of your descriptor, assuming that it is a 3 part composite key, then your ReadObjectQuery procedure is defined correctly in the descriptor. However the ReadObjectQuery is incorrect, you must use "get" not "getField", also you must use a single expression builder.
    i.e.
    ExpressionBuilder builder = new ExpressionBuilder();
    Expression expr = (builder.get("category").equal("GOESVC.GETTDEV")).and(
    builder get("configKey").equal("GOESVC.REQ")).and(
    builder.get("value").equal("$ENV.$ORIGIN.GOESVC.REQ"));
    ReadObjectQuery query = new ReadObjectQuery(Configuration.class, expr);
    session.executeQuery(query);
    you could also do,
    Vector key = new Vector(3);
    key.add("GOESVC.GETTDEV");
    key.add("GOESVC.REQ");
    key.add("$ENV.$ORIGIN.GOESVC.REQ");
    ReadObjectQuery query = new ReadObjectQuery(Configuration.class);
    query.setSelectionKey(key);
    session.executeQuery(query);
    If the descriptor primary key is not 3 part, then add this query as a named query.
    Descriptor desc=evt.getSession().getDescriptor(Configuration.class);
    ReadObjectQuery query = new ReadObjectQuery();
    StoredProcedureCall call = new StoredProcedureCall();
    call.setProcedureName("CONFIGSVC");
    call.addUnamedArgument("CATEGORY");
    call.addUnamedArgument("CFGKEY");
    call.addUnamedArgument("VALUE");
    query.setCall(call);
    query.addArgument("CATEGORY");
    query.addArgument("CFGKEY");
    query.addArgument("VALUE");
    desc.getQueryManager().addQuery("findConfigSVC", query);
    To execute the query,
    Vector arguments = new Vector(3);
    arguments.add("GOESVC.GETTDEV");
    arguments.add("GOESVC.REQ");
    arguments.add("$ENV.$ORIGIN.GOESVC.REQ");
    session.executeQuery(Configuration.class, "findConfigSVC", arguments);

  • Trying to override the default af:tree expanded and collapsed icons

    Hi,
    I initially hijacked a thread from 2010 that was vaguely similar to what I need to ask, but a kind forum moderator split my post out to stand on its own merits.
    I am trying to override the default af:tree expanded and collapsed icons I am using the following styles for my af:tree but they are not reflecting any thing on my tree with the styleclass orgType.
    af|tree.orgType::expanded-icon {
    content: url("../images/ac-expand.png");
    cursor: default;
    af|tree.orgType::collapsed-icon {
    content: url("../images/ac-collapsed.png");
    cursor: default;
    af|tree::expanded-icon {
    content: url("../images/folder_open.png");
    cursor: default;
    af|tree::collapsed-icon {
    content: url("../images/folder_close.png");
    cursor: default;
    After working for long hours I realized that there is some problem with af:tree and treeTable. They are not taking the styles where as for the other components, every thing works fine. Is there any way to achieve the task. Could you suggest any alternative way to do this. Thanks in advance. Your suggestions for this task can really help me and my team a lot.
    Regards,
    Krishna Sumanth.

    Hi,
    do the icons show without the style class reference used in the skin file? If so, then the style class for this component might be rendered differently for the tree, e.g.
    .orgType af|tree ...
    Frank

  • How can I control the Product Category in the Pre-select screen

    Dear ,my expert :
       I  work in ROS scenario . In my case ,the supplier can select Product Category A, Product Category B,and Product Category C when they  filled the data in the  registration scren . And the purchaser A just is responsibility for the Product Category A ,and the purchaser B ,C are the same situation .
      So ,my question is :
       1,How can I control the Product Category in the Pre-select screen? I mean that the Purchaser A can just select the   Product Category A in the Pre-select screen .
       2,You know the supplier select two category  is one BP in the system ,So if the purchaser A accepe the supplier ,the purchaser B will find the status is "accepted ",So the purchaser B will be confused about it .
       SO ,in my case ,any one has the suggestions ,any link welcome .
       Bestregards
      alex

    Hi Alex,
    As per standard SRM solution, this is not supported. Purchasers who accept new suppliers, accept them on the whole and not for any specific product category. There is no such thing as Purchaser being responsible for specific prod category in ROS.
    What you could do however is to build a custom workflow to achieve it. You could have category approvers after the purchaser has accepted the supplier. Based on the category provided by the supplier in the reg form, you could route these suppliers to appropriate category approvers.
    Regards,
    Nikhil

  • How to override the default delete operation

    Hi,
    I am new to Jheadstart, java coding for that matter.
    Here's my situation,
    I have a view which is based on a function (function returns a collection).
    I have created instead of triggers on this view to perform insert/update/delete operations.
    All these DML operations work as expected in Oracle database.
    Now, I created an Entity object and a view object on this view in my jheadstart project.
    When I run this Jheadstart application my insert and search operations run fine but update and delete operations fail with JBO-26080 error.
    The underlying oracle error is "ORA-02014: cannot select FOR UPDATE from view with DISTINCT, GROUP BY, etc."
    I know that delete and update operations work fine in Oracle and hence I would like to override the default Jheadstart operations. Can any body tell me how can I do it or point me in right direction?

    Hi,
    From the JHeadstart Developer's Guide, chapter TroubleShooting - Problem Assessment:
    If you are getting a JBO error (Business Components for Java error), try to perform the same data retrieval or data manipulation action using the BC4J Tester. You can
    invoke the tester through a right-mouse-click on the BC4J application module. If you get the same error using the BC4J tester, the problem is in the BC4J object definitions. If you added business rules, or other custom code to your BC4J objects that executes during your data retrieval or data manipulation action, you can debug this code line-by-line by running the tester in debug mode. You can also look up the JBO error in the JDeveloper online help, for each error possible causes and how to solve them are described.
    It sounds to me like you will also get this error in the BC4J Tester. This means that the problem is not related to JHeadstart. You can go to the JDeveloper discussion forum http://otn.oracle.com/discussionforums/jdev.html and ask your question there without mentioning JHeadstart. Maybe there is some switch you can set in the BC4J object to let BC4J not use SELECT FOR UPDATE.
    Hope this helps,
    Sandra Muller
    JHeadstart Team

  • How to override the default height of tree component...

    Hi,
    Can anyone please tell me how to override the default height of <af:tree> component.
    Actual Problem:
    I have a PanelBox in which I have a ShowDetail component. ShowDetail contains Tree component. When I click on ShowDetail item the Tree component have to be displayed. But, PanelBox is expanding to TREE default height(27.27 ems) instead of expanding to exact height of Tree.
    How to manage this issue?
    Thanks
    -Sukumar

    Did you already try
               <af:treeTable value="#{bindings.DashProjectPhasesDev.treeModel}"
                                  var="node"
                                  selectionListener="#{bindings.DashProjectPhasesDev.treeModel.makeCurrent}"
                                  rowSelection="none" rowBandingInterval="0"
                             inlineStyle="width:810px; height:1100px;"> Check the last line with inlineStyle...
    Julian

  • ADF &CSS :overriding the default ADF:tree icons and CSSs

    Hi,
    I have major layout issue regarding ADF:tree, how can I override the default icons?
    I override the oracle CSS with my own, but when I did that, the tree images has changed, its now small hideous triangles, I copied some lines from the oracle CSS and it worked, but the small triangles still show inside the images, how can I remove those triangles, or can I write something in my CSS to override them?
    Thanks in prior,
    Ahmad Esbita

    Ahmad,
    According to bug 5682799, you cannot work around this in the current JDeveloper release. It is fixed in 10.1.3.3 (due out "soon," perhaps as early as 15th June, according to another post on this forum)
    John

  • Overriding the default heap size of 64mb

    I run the java program on my pc on windows xp
    I need to increase the heap size, currently I launch the jar file using a batch file, the contents of the batch file are:
    java -Xms64m -Xmx512m -jar Lines.jar
    I have set the min and max heap size and when I click on the .bat file it launches the jar file with tose heap settings
    But I do not want to launch the jar file in this way(I don't want to use a batch file), is there anyway to override the default heap size for the java program to 512mb so that every time I launch the jar file the heap size is 512mb??
    Edited by: muddy777 on Sep 23, 2009 6:30 PM

    Vikash.SunJava wrote:
    set this in some machine startup like a scheduled task at machine startup
    java -Xms64m -Xmx512m
    This this will be default JVM settings.Huh?

  • IWork overrides the default app system

    iWork overrides the default app system. When I select a pages (or keynote or numbers) file, get info, set the default application to Pages '09 and click "change all" it does not honor my choice of default application. It reverts back to the new iWork. I need to use '09 for now but I don't necessarily want to delete the new version.
    Thanks, Apple for making my decisions for me. GRRRRRRRRR
    Anyway to override this? I'm getting tired of "open with" rather than just double clicking files.

    Using Get Info to change all documents to open with Pages 4.3 doesn't work. It will work on individual files, but that could be a lot of files to reset.
    This is what works for me. After I installed the new iWork updates I created a folder on an external drive & named it "other applications." I then moved the new iWork apps to this folder & renamed the applications Keynote 6, Pages 5 & Numbers 3. I have icons for two versions of Pages & Numbers (I rarely use Keynote) in my Dock. Even with two versions of Pages & Numbers running, double-clicking an existing file opens in Pages 4.3 or Numbers 2.3. This should also keep the Mac App Store from nagging you to update.

  • [svn:fx-trunk] 12963: Add IDebuggerCallbacks.terminateDebugTarget(), so that the debugger can override the default termination behavior.

    Revision: 12963
    Revision: 12963
    Author:   [email protected]
    Date:     2009-12-15 10:34:20 -0800 (Tue, 15 Dec 2009)
    Log Message:
    Add IDebuggerCallbacks.terminateDebugTarget(), so that the debugger can override the default termination behavior.
    Modified Paths:
        flex/sdk/trunk/modules/debugger/src/java/flash/tools/debugger/DefaultDebuggerCallbacks.ja va
        flex/sdk/trunk/modules/debugger/src/java/flash/tools/debugger/IDebuggerCallbacks.java
        flex/sdk/trunk/modules/debugger/src/java/flash/tools/debugger/concrete/PlayerSession.java
        flex/sdk/trunk/modules/debugger/src/java/flash/tools/debugger/concrete/PlayerSessionManag er.java

    Gordon, it looks like its been a while since you made this post.  Not sure how valid it is now...   I am particularly interested in the LigatureLevel.NONE value.  It seems that it is no longer supported.
    How do I turn of ligatures in the font rendering?
    My flex project involves trying to match the font rendering of Apache's Batik rendering of SVG and ligatures have been turned off in that codebase.  Is there any way (even roundabout) to turn ligatures off in flash?
    Thanks,
    Om

  • How to change the product category on the item level of a Sales order

    1) For each product there are Basic Product Hierarchy and Sales Product
    Hierarchy.
    2) when creating sales order, system gets the Sales Product Hierarchy
    on the Item level with the default logic.
    So our question is: how to change the logic to let system get the Basic
    Product Hierarchy on the Item Level.

    Hi,
    I believe the POSTING DATE will appear on the accounting document
    In the Accounting document, the posting date will be based on the  Billing date.
    Please let me know if you need any more details
    santosh

  • [AS] Making "keep overrides" the default graphic layer option for all placed graphics?

    If I relink thisLink when it is missing, and update link option was set to keep overrides, everything is fine. But if it was set to application settings, I am in a world of hurt, because suddenly all my Unit numbers will show 1-32 piled on top of each other (all layers visible in Photoshop) or the wrong one (just one layer visible in Photoshop) or nothing at all!
    The catch-22 is that until I relink missing links, update link option only shows "unknown" as the result. Arrrgh?
    set myLinks to every link whose status = missing
    repeat with thisLink in myLinks
        get update link option of graphic layer options of parent of thisLink
            -->Returns "unknown" instead of "application settings" or "keep overrides"
        try
            set update link option of graphic layer options of parent of thisLink to "keep overrides"
            relink thisLink to newLinkPath
            update thisLink
        on error
            -->This always errors on the set update link option line
        end try
    end repeat
    Anyone know a way around this or should I just change my name to Yossarian?
    Thanks in advance,
    Eric.

    Well, I give you points for creativity! Unfortunately, relink is destructive and overwrites any info with the default (which in CS2 is application settings).
    What really kills me is that InDesign has some Sooper Seekrit internal list that only the Links palette knows about. So if you *manually* try and relink the document and then revert it, it automatically relinks against all the paths you've tried since launching it and therefore, the second time all the links show as linked and the process is non-destructive, unlike the "relink" command.
    Argh.
    I will think on it some more though. Thanks for your input!
    PS: Adobe apparently broke the ability to relink against a string in CS4 from what I can tell. In spite of the fact that the dictionary specifically lists alias or string or string (yes, says or string twice in the dictionary), only alias really seem to work.
    So...
    set newLinkFolder to "" & path to home folder & "Pictures:"
    set newLinkPath to newLinkFolder & name of thisLink
    try
    relink thisLink to newLinkPath
    on error
    display dialog "FAIL!"
    end try
    try
    relink thisLink to newLinkPath as alias
    on error
    display dialog "No fail. You'll never see this message!"
    end try

  • How restrict all products of a Product category in the Campaign Plan

    Hi,
      Could you please suggest me how to restrict all the list of products of a product category in CRM_MKTPL transaction ( Marketing Planner ).
    Standard SAP behavior is to "explode" the category to list all products within the category onto the marketing or campaign plan.
    The requirement is to display only the Product Hierarchy but not all the products under that Product Hierarchy.
    Regards,
    Sampath Kumar Chinta.

    Hello Sampath,
    One of the prerequisite for this is define product hierarchy in the customizing
    IMG>Marketing Planning and Campaign Management>Product Assignments>Assign Product hierarchies.
    Product categories are assigned to Hierarchies, when a product category is included in a Campaign, it picks up data from the relevant hiererchy.
    Hope this helps.
    regards,
    Muralidhar Prasad.C

  • Automate: Override the default NFS version 4 domain

    Hi
    I configured a Solaris 10 jumpstart server. Everything is working without any problems. But there is this one question which I don't know how to automate:
    This system is configured with NFS version 4, which uses a domain name that is automatically derived from the system's name services. The derived domain name is sufficient for most configurations. In a few cases, mounts that cross different domains might cause files to be owned by "nobody" due to the lack of a common domain name.
    Do you need to override the system's default NFS version 4 domain name (yes/no) ?
    I found a hint in another post, so I tried the following in a finish script:
    #!/bin/sh
    cp ${SI_CONFIG_DIR}/.NFS4inst_state.domain /a/etc
    But it didn't work.
    Thank you in advance
    Janine

    You can try: this work on 10beta72
    1. copy in nfs default file into /a/etc/default/nfs
    2. /bin/touch /a/etc/.NFS4inst_state.domain

  • When installing SQL Server is there a benefit to overriding the defaults for the Shared Feature Directory?

    When installing SQL Server under feature selection you are given the option to change the Shared feature directories. When you choose to change from the default OS drive it seems that the installation
    process still installs a large amount of files on the OS drive and then additional files under a similar drive structure on the alternative drive. Is there any real benefit to changing the default location?
    Additional is there benefit to changing the default location for the installed features, database engine etc. We are trying to create some clean templates that we can bring up in our production
    environment so we are provisioning separate drives for data, logs, backups, tempdbs but as we use the prepare image it seems like splitting the installation of sql server into two separate locations to safe minimally on file space seems counterproductive.
    I have searched for best practices and this area seems glossed over in most articles, I found a few that indicate later installation of features on a machine that use a non-standard shared component
    drive has caused issues. I would like to know there are  benefits to taking such actions.
    Thanks in advance,
    Dirk

    Hello,
    The best reason I can think about installing SQL Server binaries on another drive different than the system drive is the
    fact the page file (pagefile.sys) is located on the system drive by default. The more I/O I can prevent happening on that drive the better for the performance of operating system.
    SQL Server still installs some binaries on the system drive anyway, and creating a partition for SQL Server binaries alone
    may seem like a waste.
    Hope this helps.
    Regards,
    Alberto Morillo
    SQLCoffee.com

Maybe you are looking for