Selection dynamic Mapping Runtime Constant with a qualifier

Hello all,
i want to access a Mapping Runtime Constant out of a message mapping specified with a qualifier.
In the Integration Directory i specified in the identifier tab the following Value Pairs:
Agency               Scheme          Name
http://Sap.com/xi/XI    XIParty         ABC
R3D_310                 Partner         111
R3T_310                 Partner         222
R3P_310                 Partner         333
In the message mapping i want to have the Name for the agency "R3T_310".
I know i can access the Name with:
constant = (String) map.get(StreamTransformationConstants.SENDER_PARTY);
But i getting everytime the name "ABC", which i don't want.
At this point i need your help, to find out how i can dynamically get the correct one??
many thanks for your help
ilka

Ilka,
You can also access other Mapping Runtime constants. For example, SENDER_PARTY_AGENCY.
If needed, you can also access SENDER_PARTY_SCHEME and SENDER_SERVICE.
The SAP Help link for all the Mapping Runtime constants accessible with StreamTransformationConstants is:
http://help.sap.com/saphelp_nw04/helpdata/en/78/b4ea10263c404599ec6edabf59aa6c/frameset.htm
Hope this helps,
Bhanu

Similar Messages

  • Mapping runtime constant to get system details of the XI box

    Hi
       We have a need to get the XI system details ( sysid and the client) at runtime - when executing a mapping that we designed using Message mapping . Is there any runtime constant/udf that we  can use to retrieve this information ?
    We are on XI 3.0 SP23.

    Hi,
    refer this blog by Michal..
    /people/michal.krawczyk2/blog/2005/06/11/xi-how-to-retrieve-messageid-from-a-bpm
    just ignore the BPM part...you will need only the mapping logic and your target message will have the necessary value...also refer this link for the list of parameters that you can access:
    http://help.sap.com/saphelp_nwpi71/helpdata/en/b3/9a2aeb24dc4ab6b1855c99157529e4/content.htm
    http://help.sap.com/saphelp_nwpi71/helpdata/en/78/b4ea10263c404599ec6edabf59aa6c/frameset.htm
    Regards,
    Abhishek.

  • Idoc mapping into E1IDB02 with different qualifiers

    Hi,
    I have to map a flat file to an Idoc (PEXR2002). Problem is in the flat file I have debitor and creditor informations wich have to be mapped into the same target segment named E1IDB02 with different qualifiers (BA for debitor and BB for creditor). Has anyone an idea how to do this?

    Hi,
    Right click on this Segment E1IDB02 in the target nessage in the message mapping and say Duplicate Subtree.
    Now, you can give each rule individually to this target element.
    regards
    Bhavesh

  • Accessing runtime constants with XSLT doesn't work

    Hi PI-experts,
    I'm trying to insert the Message ID from my message in a XSLT Mapping. I followed the description in SAP Help:
    First declare a param:
    <xsl:param name="MessageId"/>
    Later, use it:
    <MESSAGE_ID><xsl:value-of select="$MessageId"/></MESSAGE_ID>
    But the field MESSAGE_ID is always empty.
    Any explanations ?
    What do I need to do, to make it work ?

    Hi Udo and all,
    i have a bpm, where i first collect some messages and then execute a transformation step, which calls a XSLT Mapping to merge multiple messages into one. After this Transformation Step i added another Transformation Step, which calls a Message Mapping. This Message Mapping is a one to one mapping (every field in the source gets mapped to its twin in the target structure, both messages are the same). Only one field is changed, i wrote user-defined function as proposed in Michal's blog, retrieve the MessageID and set it to this field. I tested the BPM and it definitly works, the Message ID is set to the correct value.
    Is this a different behaviour than you have experienced in the past?
    I'm running on PI 7.0 with SP 16.
    Best Regards
    Sven

  • XSLT mapping, how can I include a Runtime Constants in target message

    Hi, I would like in my XSLT mapping, to have an attribute include the MessageID.
    From my understanding of the online help [http://help.sap.com/saphelp_nw04/helpdata/en/73/f61eea1741453eb8f794e150067930/content.htm|http://help.sap.com/saphelp_nw04/helpdata/en/73/f61eea1741453eb8f794e150067930/content.htm], I have the following code in my XSL:
                   <xsl:param name="MessageId" />
                   <xsl:attribute name="filename">Output_<xsl:value-of select="$MessageId"/>.xml</xsl:attribute>
    But for now the result is to have a filename attribute that only contains: "Output_.xml" as if the $MessageId is empty.
    Anyone experienced successfully using one of those runtime constants with XSLT mapping ?
    Cheers,
    greg

    Hi, found the answer of why it was not running: I'm in a transform step of a BPM:
    For more info check this thread:
    [/message/435521#435521 [original link is broken]|/message/435521#435521 [original link is broken]]

  • Runtime constant: mapping-programm

    Hello,
    we got a exception branch for mapping errors in BPM.
    Now we want to inform the user, which mapping programm caused the error.
    Is there a runtime constant?
    I already analyzed:
    http://help.sap.com/saphelp_nw04/helpdata/en/b3/9a2aeb24dc4ab6b1855c99157529e4/content.htm
    Regards Mario

    Hi Mario,
    You can raise alerts if mapping, receiver determination etc.. fails in the integartion engine. You need to configure alert rules for this. You can go to RWB->Alert Configuration->Where did the error occur? choose integration engine and you can see different error categories and error codes which can be configured using alert rules. Refer this michal's weblog for configuring the same..
    /people/michal.krawczyk2/blog/2005/09/09/xi-alerts--step-by-step
    You can also raise an alerts from BPM for any mapping failures, send step system errors/application errors using fault messages (through exception branch).
    Refer this weblog for configuring an alert in the BPM
    /people/michal.krawczyk2/blog/2005/03/13/alerts-with-variables-from-the-messages-payload-xi--updated
    In you BPM, You can add Container Variables to Messages by using Container Opertaions(Append/Assign)
    http://help.sap.com/saphelp_nw2004s/helpdata/en/59/e1283f2bbad036e10000000a114084/frameset.htm
    http://help.sap.com/saphelp_nw2004s/helpdata/en/33/4a773f12f14a18e10000000a114084/frameset.htm
    And also you can throw this exceptions via Alerts.
    Also go through these links....
    http://help.sap.com/saphelp_nw2004s/helpdata/en/33/4a773f12f14a18e10000000a114084/frameset.htm
    /people/alessandro.guarneri/blog/2006/01/26/throwing-smart-exceptions-in-xi-graphical-mapping
    /people/sap.user72/blog/2005/02/23/raising-exceptions-in-sap-xi-mapping
    http://help.sap.com/saphelp_nw2004s/helpdata/en/80/942f3ffed33d67e10000000a114084/frameset.htm
    /people/michal.krawczyk2/blog/2005/09/09/xi-alerts--step-by-step
    /people/aravindh.prasanna/blog/2005/12/23/configuring-scenario-specific-e-mail-alerts-in-xi-ccms-part--1
    Regards,
    Abhy
    Message was edited by: Abhy Thomas
    Message was edited by: Abhy Thomas

  • Map the parameter with dynamic value.

    Hi,
    can be map our variable with some dynamic values??
    like suppose I have a variable in which I want to fill current value every time like current date or current time to my variable.
    is there any way to customize the variable in this way?
    thnx
    USoni

    USoni
    In OFT you can generate user variables by:
    Edit -> Databank Wizard -> Add Variable; then select Internal - Specify Expression as the type then you can enter Date() in the expression text field, to call the system date or Time() to call the system time.
    Unfortunately since the removal of VBA that is all OFT can do
    In OpenScript however you can use Java code view to substitute the parameter value with any Java expression, or for the date you can change the parameter value for *{{@today(MM/dd/yyyy)}}* which will return the date with the format MM/dd/yyyy, calling *{{@today(dd/mm/yyyy)}}* would return the current date with the format dd/mm/yyyy etc ...
    There is a list of pre-build functions on the help files, and if you need something that is not there and have not Java skills you can post the specific question here and I'm sure someone will post the code.
    Regards
    Alex

  • Mapping Runtime with multiple gateway registration

    I need a help about increase mapping performance.
    I have add new Java server on new server(I mean HW).
    I wonder if ABAP(I mean RFC Gateway with JCo) can recognize this "New" Java server.
    I reference following...
    http://help.sap.com/saphelp_nw04/helpdata/en/1c/ba295ee20fcd41b6804f1bc602de68/content.htm
    https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/library/xi/3.0/sap exchange infrastructure tuning guide xi 3.0.pdf
    -->See section "Mapping Runtime"
    I have a following XI3.0 system.
    EOne central Instance(ABAP and Java) on one server(HW).
      Java have one J2EE Dispatcher and one Server.
    EOne dialog Instance(ABAP and Java) on one server(HW)
      Java have one J2EE Dispatcher and one Server.
    So "Java" have two Server processes on each hardware.
    You know when mapping, ABAP connect to Java with JCo.
    In ABAP side, I defined as AI_RUNTIME_JCO_SERVER(SM59).
    In Java side, I defined as AI_RUNTIME_XI1(visual admin)
    They have set same "Program ID" and test connection well.
    Now I add new Java server node.
    I can see "New" Java server tree in visual administrator.
    Can I defined RFC Destination "AI_RUNTIME_XI1" to this New one? (This is same destination.)
    Tunning Guide said, "load distribution by multiple gateway registration".
    What's mean?? I have only one Gayteway(I mean AI_RUNTIME_JCOSERVER)...
    Help.sap.com said, "The RFC Engine service can register under one name to one particular gateway. To register to another gateway, another name has to be used. ".
    What's mean?? Can XI ABAP Gateway recognize "another name"?
    I confuse a bit...
    regards,

    Hi All,
    In addition to the above, if mapping is tested within ESR there is no issue. The problem is happening only during runtime.
    BTW, When we applied the note 1838921 we upgraded the Adapter Framework from SP09 to SP12.
    Could this be an issue?
    Regards,
    Sudheer

  • How to map IDoc segment with qualifiers

    Hi everyone!
    I have the following problem: In an IDoc of type DESADV01 there can be several segments of type E2EDS01. Each segment has a different qualifier, which is the value of the field SUMID in this case. My target structure (type EDIFACT) now has several segments, each again with a sort of qualifier. Now I have to map the values of certain source segments to the respective target segments.
    Exaple (in XML format):
    Source
      <E1EDS01 SEGMENT="1">
        <SUMID>021</SUMID>
        <SUMME>0000000001.000</SUMME>
        <SUNIT>KGM</SUNIT>
      </E1EDS01>
      <E1EDS01 SEGMENT="1">
        <SUMID>022</SUMID>
        <SUMME>0000000001.000</SUMME>
        <SUNIT>KGM</SUNIT>
      </E1EDS01>
    Target
      <S_MEA>
        <C_C502>
          <D_6313>N</D_6313>
        </C_C502>
        <C_C174>
          <D_6411>KGM</D_6411>
          <D_6314>1</D_6314>
        </C_C174>
      </S_MEA>
      <S_MEA>
        <C_C502>
          <D_6313>G</D_6313>
        </C_C502>
        <C_C174>
          <D_6411>KGM</D_6411>
          <D_6314>1</D_6314>
        </C_C174>
      </S_MEA>
    (i have omitted several details here, but I'm only interested in the general procedure anyway).
    So in general the source segment with qualifier "021" should be mapped to a target structure with qualifier "N" etc.
    How can this be done using standard XI mapping techniques?
    Regards, Joerg

    Hi everyone!
    Thanks for your input data - unfortunately this wasn't quite what I was looking for. However I thik I solved my original problem and I just wanted to share this solution with you - maybe it helps others, maybe some of you have suggestions what I could do differently.
    To sum up the requirement: There can be multiple input segments, each with a certain qualifier. These input segments have to be mapped to the target segments, respectively - however, the qualifiers change. There can be several segments with qualifiers that do not match the requirement, and required segments might be missing.
    So here's what I came up with:
    Use the qualifier of the source segments as an input to a <b>FixValues</b> function. In this function, map the desired qualifiers to the value <b>true</b>, use <b>false</b> as the default value. Map the output of the <b>FixValues</b> function to a <b>createIf</b> function and use this to create the desired output segment. This way, for each of the required segments, one target segment will be created. All other segments (with unwanted qualifiers) will be removed.
    So far, this technique worked for me - do you have improvements/suggestions?
    Regards, Joerg

  • How to dynamic select based on runtime value ?

    how to dynamic select based on runtime value ?
    I want to write a select function, which do selecting based on parameters. eg,
    CREATE OR REPLACE FUNCTION myfunction
    (tableName VARCHAR2, pkName VARCHAR2, pkValue VARCHAR2, requestString VARCHAR2)
    RETURN VARCHAR2 AS
    BEGIN
    select requestString from tableName where pkName=pkValue;
    RETURN NULL;
    END;
    myfunction('users', 'user_id', '100', 'user_name'); it will select 'user_name' from table 'users' where 'user_id' = '100'.
    This way could save lots of coding. but it can't pass compiler. how to work out ?
    Thanks.

    While this may save code, if used frequently it will be ineffecient as all [explicative deleted]. The danger is that it would be used even for repeatable statements.
    This mode of operation ensures that every statement [calling the funciton] needs to be reparsed, which is extremely expensive in Oracle (in CPU cycles, recursive SQL and shared pool memory).
    Such reparsing is rarely a good thing for the environment ... it could easily lead to buying more CPU (bigger box) and therefore adding more Oracle license ... which could quickly exceed the typical developer's salary.
    However - if you really, really want to do this, look up 'execute immendiate' in the PL/SQL manuals.

  • Ipsec Stateful Failover issue with Dynamic-Map

    Hi all, I have an issue with a couple of Cisco ISR 2921 in Ha Ipsec Stateful Failover configuration.
    With static crypto-map, stateful works good, Ipsec sessions are correctly trasmitted from Cisco Active router to Cisco Standby router.
    With dynamic-map and profile, stateful fails, Ipsec sessions are not correctly trasmitted from Cisco Active router to Cisco Standby router.
    I tried different IOS version:152-1.T3, 152-3.T2 and 153-1.T but I have the same behavior.
    Could you help me?
    Marco

    Yes it is supported. It is supprted on VAM, VMA2, VAM2+.

  • Runtime Constant in XSLT :-(

    Hi together,
    I have one problem with constant at the runtime.
    The tag <RCVPRN> is empty, but I need this for my IDoc communication.
    In the SAP help stands this:
    Runtime Constants
    $ReceiverService
    Service on the receiver side that receives the message. For example, the name of a business system.
    As of SAP XI 3.0, use this constant instead of the constant RECEIVER_SYSTEM used previously.
    Yes
    See also: Service
    If you want to access one of the constants in the XSLT program, you first have to declare the constant as a parameter, for example:
    <xsl:param name="MessageId" />
    In my XSLT mapping I have this:
    <RCVPOR>empty</RCVPOR>
    <RCVPRT>LS</RCVPRT>
    <xsl:param name="ReceiverService"/>
    <RCVPRN>
    <xsl:value-of select="$ReceiverService"/>
    </RCVPRN>
    </EDI_DC40>
    But during the runtime the constant is empty
      <RCVPOR>empty</RCVPOR>
      <RCVPRT>LS</RCVPRT>
      <RCVPRN />
       </EDI_DC40>
    Have you an idea for my problem?
    Bye
    Stefan

    Hi Udo/all,
    Thank you for your answer.
    Please see in my last post:
    Idoc with XSLT Mapping ALE service error
    I mark in my channel:
    Take Sender from Payload and Take Receiver from Payload
    I must set control field by xslt maping, because the receiver is flexible.
    With your setting I became a converting error to an ALE logical system.
    I need the runtime constant in the xslt mapping.
    Idea?
    bye
    stefan

  • Creating Forte FieldWidgets Dynamically at Runtime

    Hi Everyone,
    Could someone please help me with the following problem I have when
    creating Forte fieldwidgets dynamically at run-time. I am using Forte
    ver. 3.0.G.2.
    (-1-) I have a window class with an empty gridfield, <grfMain>, inside a
    viewport. The idea is to populate the gridfield with DataField
    fieldwidgets dynamically at runtime. Depending on some input criteria,
    sometimes some of the DataFields need to map to IntegerNullables, some
    to DoubleNullables and some to DateTimeNullables. (Please note that I
    cannot use the Forte window workshop to create these fieldwidgets,
    because different types of fieldwidgets will be needed at different
    times, in different numbers, at run-time. ) Here is a sample of how I am
    currently trying to achieve this:
    dfDate : DataField = new;
    dfDate.MaskType = MK_Template;
    dfDate.DateTemplate = new( value='dd/mm/yyyy' );
    dfDate.Row = 1;
    dfDate.Column = 2;
    dfDate.Parent = <grfMain>;
    dfInt : DataField = new;
    dfInt.MaskType = MK_INTEGER;
    dfInt.Row = 2;
    dfInt.Column = 2;
    dfInt.Parent = <grfMain>;
    dfReal : DataField = new;
    dfReal.MaskType = MK_FLOAT;
    dfReal.Row = 3;
    dfReal.Column = 2;
    dfReal.Parent = <grfMain>;
    The code above is called after the window has been opened with the
    Open() statement.
    Looking at the code above, one obvious omission is that the "Mapped
    Type" of the Datafields are not set up. In the Forte window workshop, an
    interface is provided to set up the "Mapped Type" of the Datafield
    widgets, but I'm not sure how to do that dynamically, and that is
    basically my biggest problem here.
    (-2-) If I now run the window class, the Datafield widgets get created,
    and they all have the correct input maks, but no validation gets done
    when one tabs away from the field. For example, Datafields with
    MaskType=MK_INTEGER will gladly accept '--1--0++7', while Datafields
    created in the window workshop (mapping to IntegerNullables) will do a
    validation, and not allow one to tab out of the field before the extra
    minus and plus signs are not removed.
    I have the same problem with the Datafields which have
    MaskType=MK_Template and DateTemplate='dd/mm/yyyy'. For the date, one
    can enter something like '2*\**\****', and leave the field, while the
    same type of datafield created in the window workshop (mapped to a
    DateTimeNullable), will not allow you to leave the field before a valid
    date has not been entered. To summarise, the input masks of my
    dynamically created Datafields work fine, but no validation gets done
    when the field looses the focus.
    (-3-) As a test, I used the Forte debugger ("view"-"local variables") to
    look at the differences between Datafields created dynamically, and
    those created in the Forte window workshop. One very obvious difference
    was that Datafield attribute "MapTypeName" was filled in for the window
    workshop Datafields, but not for my dynamically created Datafields. The
    problem is that Forte does not allow me to set this attribute
    dynamically in my code. How else can I setup the Mapped Type
    dynamically?
    (-4-) In order to have a consistent look-and-feel throughout our Forte
    project, we are making use of Domain classes for DATE and DECIMAL data
    entry fields. My questions are:
    (4.1) How must I go about creating Datafields dynamically that make use
    of these Domain classes?
    (4.2) Is it also a matter of setting up the "MapTypeName" attribute,
    which I cannot seem to do?
    (4.3) Is the mapping done differently for Domain classes?
    (-5-) Another interesting thing to note for Datafields created in the
    Forte Window Workshop, is that if the mapped type is IntegerNullable
    with Input Mask = Integer, or DoubleNullable with Input Mask = Float,
    then the Object that the Datafield widget maps to, must first be
    instantiated before the Loose-Focus validations will start to work. For
    example, if a Datafield widget called "dfTestInt" was created in the
    Forte window workshop, which maps to an IntegerNullable, and Input Mask
    = Integer, then the following line is needed before the window is
    displayed: dfTestInt = new;
    Without this line, one can enter something like '2---3+++7', and leave
    the field.
    This is not true for Datafields where the mapped type is
    DateTimeNullable with say Input Mask Template='dd\mm\yyyy'. In this case
    validations are done even thought the object being mapped to, has not
    been instantiated yet. In other words you will never be able to enter
    '2*/**/****', and leave the field for datafield created in the window
    workshop. Maybe in this case the validation is being done by the
    template itself?
    Thanks in advance
    Riaan
    To unsubscribe, email '[email protected]' with
    'unsubscribe forte-users' as the body of the message.
    Searchable thread archive <URL:http://pinehurst.sageit.com/listarchive/>

    what I mean is rendering JSF components on the fly, becuase some time you don't know things at design time. Lets say I am designing a page in creator that shows the total number of dependants that belongs to a primary inusrance member in text boxes. Of course we don't know in advance how many dependants we have for a specific member unless we go to databse and fetch all the data at runtime. Desiging some thing dynamic like that is very easy in CGI or ASP/JSP but JSF model seems very static due to it's design time feature.
    So is it possible with JSF or not?

  • OA Framework LOV – How to add where clause dynamically at runtime

    Hi All,
    Following is my page design:
    MainAM (This is root Application module) Package is: mycompany.oracle.apps.<product>.<project>.server
    MainPageVO (This is the View Object associated to Main AM)
    LovAM (This Application module is for LOVs) Package is: mycompany.oracle.apps.<product>.<project>.lov.server
    FileNameLovVO (This is the View Object is for "File Name" LOV. It is associated LovAM)
    I my main page is attached to the "Main AM". In the main page, I have a custom search region and in that there is a messageLovInput type of field based on "FileNameLovVO". The field name is File Name.
    Use Case:
    When a user opens the page, I determine user type. If the use is a clerk (not a superuser) then I need to restrict values in my File Name LOV by setting where clause dynamically.
    Issue1:
    ====
    In the main page controller when I do following, OA Framework is not able to access the "FileNameLovVo".
    1. Following code is from the main page's controller:
    String userId = 100;
    LovAMImpl lovAm = new LovAMImpl();
    Serializable[] lovParameters = {userId};
    Class[] lovParamTypes = { String.class };
    lovAm.invokeMethod("initLovQuery", lovParameters, lovParamTypes);
    2. In LovAMImpl class I have created following method:
    public void initLovQuery(String useId)
    FileNameLovVOImpl fileNameLovVo = getFileNameLovVO1(); // ******This returns NULL*******
    if (fileNameLovVo == null)
    MessageToken[] errTokens = { new MessageToken("OBJECT_NAME", "getFileNameLovVO1")};
    throw new OAException("AK", "FWK_TBX_OBJECT_NOT_FOUND", errTokens);
    fileNameLovVo.initQuery(userId);
    In the above code "FileNameLovVOImpl fileNameLovVo = getFileNameLovVO1();" is returning NULL.
    Please let me know what am I missing here.
    I resolved above issue with following work around:
    1. Attached "FileNameLovVO" to "MainAM"
    2. Moved initLovQuery(String useId) method to "MainAMImpl" class.
    Is that the correct way? I would prefer NOT to attach "FileNameLovVO" to "MainAM". Any suggestions?
    Issue2:
    ====
    After using above work around I tried to set WHERE clause dynamically:
    FileNameLovVO is based on following SQL query:
    SELECT DISTINCT file_name FROM <table> WHERE USER_ID like :1
    I need to pass value for USER_ID if the user is a clerk and I need to pass '%' if the user is a supper user. I'm passing value in "LovVo.initQuery(userId)" method using following code:
    public void initQuery(String userId)
    StringBuffer whereClause = new StringBuffer(1000);
    Vector parameters = new Vector(1);
    int bindCount = 0;
    setWhereClauseParams(null);
    if ((userId != null) && (!("".equals(userId.trim()))))
    parameters.addElement(servicerId);
    whereClause.append(++bindCount);
    if (bindCount > 0)
    Object[] params = new Object[bindCount];
    parameters.copyInto(params);
    setWhereClauseParams(params);
    executeQuery();
    When I select LOV at runtime in the page, it fails with following error:
    oracle.apps.fnd.framework.OAException: oracle.jbo.SQLStmtException: JBO-27122: SQL error during statement preparation. Statement: SELECT * FROM (SELECT DISTINCT file_name FROM <table> WHERE user_id LIKE :1) QRSLT WHERE (( UPPER(FILE_NAME) like :1 AND (FILE_NAME like :2 OR FILE_NAME like :3 OR FILE_NAME like :4 OR FILE_NAME like :5))) ORDER BY file_name desc
    OA Framework tries to create following statement:
    SELECT *
    FROM (SELECT DISTINCT file_name
    FROM <table>
    WHERE user_id LIKE :1) qrslt
    WHERE (( UPPER (file_name) LIKE :1
    AND ( file_name LIKE :2
    OR file_name LIKE :3
    OR file_name LIKE :4
    OR file_name LIKE :5
    ORDER BY file_name DESC
    Any help is greatly appreciated.
    Thanks for your help guys.
    Mitesh

    I have a lovinput item which has an external LOV attached to it - the VO uses the below sql query. I want to display the addresses of the customer accounts belonging to the customer name or account entered. I have a PPR event in the account number field which is calling the onAccountNumber method in my AM - the method is getting triggered when you enter the account number and the vo returns the rowcount as 3 exactly but if you click the lovinput item - it brings back all the addresses available instead bringing back addresses beloning to the account number.
    public void OnAccountNumber(String accountNumber,String partyName,
    Boolean executeQuery)
    System.out.println("Im here on account number" + accountNumber + " PartyName:" + partyName);
    AddressVOImpl Addrvo= getAddressVO1();
    Vector parameters = new Vector(2);
    StringBuffer whereClause = new StringBuffer(100);
    int clauseCount = 0;
    int bindCount = 0;
    Addrvo.setWhereClauseParams(null); // Always reset
    if ((accountNumber != null) && (!("".equals(accountNumber.trim()))))
    whereClause.append(" Account_Number = :");
    whereClause.append(++bindCount);
    parameters.addElement(accountNumber);
    clauseCount++;
    if ((partyName != null) && (!("".equals(partyName.trim()))))
    if (clauseCount >0){
    whereClause.append(" AND ");
    whereClause.append(" Party_Name like :");
    whereClause.append(++bindCount);
    parameters.addElement(partyName);
    clauseCount++;
    Addrvo.setWhereClause(whereClause.toString());
    if (bindCount >0)
    Object[] params=new Object[bindCount];
    parameters.copyInto(params);
    Addrvo.setWhereClauseParams(params);
    System.out.println("AddressVO:" + Addrvo.getQuery() );
    //Addrvo.executeQuery();
    System.out.println("Addr Cnt:" + Addrvo.getRowCount());
    SQL used in VO
    =========
    SELECT hl.address1
    || ' '
    || hl.address2
    || ' '
    || hl.address3
    || ' '
    || hl.city
    || ' '
    || hl.postal_code
    || ' '
    || hl.state
    || ' '
    || hl.country address,
    hca.account_number,hp.party_name
    FROM hz_cust_accounts hca,
    hz_cust_site_uses_all hcsu,
    hz_cust_acct_sites_all hcs,
    hz_party_sites hps,
    hz_locations hl,
    hz_parties hp
    WHERE hcsu.cust_acct_site_id = hcs.cust_acct_site_id
    AND hcs.party_site_id = hps.party_site_id
    AND hps.location_id = hl.location_id
    AND hca.cust_account_id = hcs.cust_account_id
    AND hcsu.site_use_code = 'SHIP_TO'
    AND hcsu.status = 'A'
    AND hp.party_id = hps.party_id
    AND hp.party_id = hca.party_id
    -- AND account_number=6028
    Can someone please tell me how to restrict the addresses lov to an entered account number or customer name??

  • Clob mapping not working with mysql

    Hi,
    I have an application that i'm running with MySQL and Oracle at the same
    time. At some point, i need to use a 'clob' mapping. When i do this, it
    just works fine with oracle but it fails with mysql. i have the exception:
    Field "com.ennov.prisma.api.document.jdo.AbstractDocumentPO.description"
    is mapped as a clob, but should be represented as a different mapping.
    If the field is a string and you would like to force it to map as a
    clob, add an extension to its field metadata with a key of "jdbc-size"
    and a value of
    -1.[com.ennov.prisma.api.document.jdo.AbstractDocumentPO.description]
         at kodo.jdbc.meta.Mappings.invalidMapping(Mappings.java:132)
         at kodo.jdbc.meta.Mappings.invalidMapping(Mappings.java:118)
         at
    kodo.jdbc.meta.ClobFieldMapping.fromMappingInfo(ClobFieldMapping.java:46)
    if i use a value mapping, it works with MySQL but fails with Oracle (I
    have sql error because a clob is used in a distinct select).
    In the manual, it is written "Note that some databases can support
    string of unlimited length without using a CLOB; when this is the case
    the mapping tool will install a value mapping in favor of
    this mapping.". So apparently, this is not the case with MySQLDictionary.
    To solve my problem and have my code working with both databases, i had
    to extend the MySQLDictionary and overwrite the replaceFieldMapping
    method in order to replace the clob mapping by a value mapping at
    runtime but i don't feel confident to do this kind of modifications by
    mysel and would expect this behaviour to be solved quite soon.
    Thanks for your help since this problem is urgent for us,
    Laurent Czinczenheim

    Laurent-
    The best solution would probably be to just have separate mappings for
    the MySQL and Oracle databases. The easiest way to accomplish this would
    be to have a separate setting for each of the databases. E.g.:
    kodo.jdbc.meta.MappingFactory: file(SingleFile=true, FileName=oracle.mapping)
    kodo.jdbc.meta.MappingFactory: file(SingleFile=true, FileName=mysql.mapping)
    That way, you can use a clob mapping for Oracle, and a normal value
    mapping for MySQL (since MySQL doesn't need to use the CLOB mapping, and
    it isn't very efficient).
    For more details on this, see:
    http://docs.solarmetric.com/manual.html#ref_guide_mapping_factory
    Another solution is to just stick with your custom extension of the
    MySQLDictionary, which is a perfectly valid way of having special CLOB
    handling in MySQL. Note, though, that CLOB handling is less efficient
    than VARCHAR handling, so it should be a mapping of last resort, and
    there isn't any need to use it in MySQL.
    In article <[email protected]>, czinczenheim wrote:
    Hi,
    I have an application that i'm running with MySQL and Oracle at the same
    time. At some point, i need to use a 'clob' mapping. When i do this, it
    just works fine with oracle but it fails with mysql. i have the exception:
    Field "com.ennov.prisma.api.document.jdo.AbstractDocumentPO.description"
    is mapped as a clob, but should be represented as a different mapping.
    If the field is a string and you would like to force it to map as a
    clob, add an extension to its field metadata with a key of "jdbc-size"
    and a value of
    -1.[com.ennov.prisma.api.document.jdo.AbstractDocumentPO.description]
         at kodo.jdbc.meta.Mappings.invalidMapping(Mappings.java:132)
         at kodo.jdbc.meta.Mappings.invalidMapping(Mappings.java:118)
         at
    kodo.jdbc.meta.ClobFieldMapping.fromMappingInfo(ClobFieldMapping.java:46)
    if i use a value mapping, it works with MySQL but fails with Oracle (I
    have sql error because a clob is used in a distinct select).
    In the manual, it is written "Note that some databases can support
    string of unlimited length without using a CLOB; when this is the case
    the mapping tool will install a value mapping in favor of
    this mapping.". So apparently, this is not the case with MySQLDictionary.
    To solve my problem and have my code working with both databases, i had
    to extend the MySQLDictionary and overwrite the replaceFieldMapping
    method in order to replace the clob mapping by a value mapping at
    runtime but i don't feel confident to do this kind of modifications by
    mysel and would expect this behaviour to be solved quite soon.
    Thanks for your help since this problem is urgent for us,
    Laurent Czinczenheim
    Marc Prud'hommeaux
    SolarMetric Inc.

Maybe you are looking for

  • Adobe Reader 11 is unable to open PDF's from Internet Explorer 11

    My boss is currently operating on the Adobe Reader 11 and often needs to use Internet Explorer 11 for certain programs. Unfortunately the Adobe Reader is unable to open PDFs from Internet Explorer and often comes up with a message telling us that the

  • Selected TOC style Name

    Hi All, Simple question for you... How can I alert the selected TOC style name. We are creating huge tool. Based on the selection Toc Style, we will process the multiple document. For example I want to alert the Toc Style CCC(tick mark) name in this

  • What is this a symbol for ⌅?

    I thought this was space bar. But the keycommands for it dont seem to be working (Play from Selection). And when i added my own custtom key command for space bar the symbol the key command manager gave me was something like this: ⊔

  • ZERO Total Costs of the Solution and No Result Log after Optimiser Run

    Hi Experts I found that after SNP optimiser run for one variant with selected product and location, the Result Log generated & Total Costs of the Determined Solution is ZERO from OPTIMISER LOG. Before optimiser run, I had run consistency check /SAPAP

  • ODD issue with the "timeline" getting moved over

    notice the left side of the timeline how its been moved from the left side of the full interface window. even if i close the projects tab on the left the timeline "still" does not default to the very left side. what happened is i was pulling a clip a