Need to decalre global data in the badi methods.

Hello Gurus,
I am struck in a weird situation, this is regarding a badi to fill a custom segment in the idoc.
I could fill all the data for the custom segement and populate it, but it is getting filled one segement above the required segment sequence. But the data i need to use to retrieve my data to populate hte custom seg is lost, once the control reaches teh badi method next time.
What my personal opinion is to declare some STATIC data in the method so that next time when teh control reaches the badi method, i can use the data stored in teh STATIC, but, i read in the sap help, that STATIC cannot be used int eh interface.
Will there be any methods in regular badis to declare like global data, so that, their data could be used all across the badis.
Thanks for your time.
Rgds.

You can declare the STATIC attribute in your implementation class.
You also want to make sure the data is not obsolete, by also storing the document number as STATIC. Like:
  if V_DOCNO ne coming_doc-no.
      clear V_STORED_DATA.
*     get new data
  endif.
Regards,
Naimesh Patel

Similar Messages

  • What is the need for setting property data inside the JMSMesage

    Hi
    Could anybody please let me know
    *What is the need for setting property data inside the JMSMesage??
    For example i have a seen a similar example as shown ??
    I have seen a
    Message.setStringProperty("Sport","Basketball");
    and also please tell me how can the MDB recievies this property data ??
    Thanks in advance .

    raviprivate wrote:
    Could anybody please let me know
    *What is the need for setting property data inside the JMSMesage??
    For example i have a seen a similar example as shown ??
    I have seen a
    Message.setStringProperty("Sport","Basketball"); Look at the detail JMS documentation on [Message Properties|http://java.sun.com/j2ee/sdk_1.3/techdocs/api/javax/jms/Message.html] .
    >
    and also please tell me how can the MDB recievies this property data ?? MDB onMessage method argument is the Message object and if you look at the documentation, Message interface has getter methods to retrieve the properties.

  • In JDBC Sender Adapter , the server is Microsoft SQL .I need to pass current date as the input column while Executing stored procedure, which will get me 10 Output Columns. Kindly suggest me the SQL Query String

    In JDBC Sender Adapter , the server is Microsoft SQL .I need to pass current date as the input column while Executing stored procedure, which will get me 10 Output Columns. Kindly suggest me the SQL Query String , for executing the Stored Procedure with Current date as the input .

    Hi Srinath,
    The below blog might be useful
    http://scn.sap.com/community/pi-and-soa-middleware/blog/2013/03/06/executing-stored-procedure-from-sender-adapter-in-sap-pi-71
    PI/XI: Sender JDBC adapter for Oracle stored procedures in 5 days
    regards,
    Harish

  • In MIGO, i need to see delivery dates from the purchase order

    Is there a way to see in transaction MIGO, the delivery dates from the purchase order?  I hope there is some exit or BADI or BAPI or .... to perform this copy function? 
    We have multi-line POs for the same material with staggered delivery dates and the Warehouse needs to know which PO line to receive against.

    when you enter the PO number in MIGO and hit enter, then you only get the items that can be received.
    If you make sure that the PO items are created by ascending delivery date, then you can always take the first.
    if you have the personal setting to display all items (even the already received ones), then you can take the first with a quantity proposal. already received items do not propose quantities.
    I would ask purchasing to tell the vendor that he has to state the PO number along with the item number in all papers (delivery note, invoice).

  • Need to add information/data to the Quote Print output for a quote

    I am trying to modify the print quote output generated after selecting a quote on the quote form. I need to know how to add information to this output.
    I am not sure where the output is selected from. How do I modify the select to include information from other tables in oracle. I am using the ASOPRINT.xsl routine. Any help would be greatly appreciated.
    Charles Harding

    Hi,
    From the xsl file I could figure out that the data for the quote lines is generated from the line <xsl:call-template name="line.table">. I would like to have some conditions added to it so that I can have particular type of items displayed on the PDF output. I am unable to figure out where I can add these conditions. Could someone help me in this? Any help would be appreciated.
    Thank You,
    Sowjanya

  • Accessing Global data in the User exits.

    Dear All,
    I want to change some fields by using the user exit "EXIT_SAPLPC61_001" for Tcode ( 1KEK ) The fields which I wanted to access are global variables, so I couldnt able to access it .so  I used field symbol and did the change  ,by calling (SAPLPC61)t_fod[] .
    But Once I change the fields and put the record back to its memory , it just posting only 2 records instead of 50 records ..
    What I understood while debugging is,  it starts the first loop and goes to user exit and change the global variable values , once the value gets changed instead of going to second loop , the loop ends ..
    we got fifty records but it just shows only 2 records as posted .
    Just throw me some lights on this issue
    Thanks
    Vivek.

    Hi VRMan,
    I do not think it's possible to use Global Variables or Functional Globals in custom Express VIs. Is there a reason why you might want to use global variables/functional global in Express VI that you've created? Perhaps you want to try just passing data to the Express VI through the connector block.
    Regards,
    Stanley Hu
    National Instruments
    Applications Engineering
    http://www.ni.com/support

  • Hello!!!I need to read some data from the serial port and processing these, at the same time I want to see the process that I am doing.

    I read the data without problems, and I see them using Waveform graph, the problem is that I want to see the real time stamps, but in the graph appears 2:00:00,000 and 01/01/04, so the date and the time is wrong !!
    Can I change this?
    I am thinking that the problem is that I have to adquire the data and the time stamps ( using Get date/time) and after, I have to represent both!!!
    Thanks!!!

    Hello,
    As you probably know a waveform is made of a beginning time (t0), a time difference between each value (dt) and an array of values (Y). Your problem is probably that you don't initialize t0. Use the Vi 'Waveform->Build a waveform' to initialize the time of the waveform.
    Hope this helps !
    Julien

  • SBL-DAT-00320: The specialized method 'Start' is not supported in the imple

    Hi.
    I have a problem. I can´t enter to siebel eCustomer for CME, looking for in the logs I found this message "The specialized method 'Start' is not supported in the implementation". I think this is because there is a workflow that is wrong.
    also, there are lovs that don´t have values, or the query don't find datas.
    Please, I need help.
    Siebel eCustomer 8.1.3
    novice

    Hi everyone
    I have the answer
    We did some personalization rules, and this rules was wrong, so we desactivate and that was the solution.

  • Syntax error while using the parameter inside the badi method.

    Hello all ,
    I'm writing a code in the badi implementation . The badi is /SAPSLL/CTRL_MM0C_R3 . this badi contains a metthod API_CONTROL_MODIFY.This badi triggers while using MIGO transaction .
    It is having the following parameter .
    IT_MSEG     Importing     Type     SLLR3_MSEG_T .
    SLLR3_MSEG_T is declared as follows.
    TYPES: sllr3_mkpf_t LIKE mkpf OCCURS 0,
                sllr3_mseg_t LIKE mseg OCCURS 0.
    here i have to get the werks value that is populated into IT_MSEG whie doing MIGO .
    I have declared a local variable and assigned werks value from the IT_MSEG to the local variable as follows
    DATA:l_werks type werks.
    l_werks = IT_MSEG-WERKS.     
    But I'm getting the following error.
    "IT_MSEG" is a table without a header line and therefore has no
    component called "WERKS".
    How should i avoid this error. Please give me sample code on how to avoid this error.
    thanks in advance
    pavan

    Hi,
    Move the row from IT_MSEG into a work area and use it. Declare the workarea of required type.
    DATA:l_werks type werks.
    read table it_mseg into wa_mseg index 1.
    l_werks = wa_MSEG-WERKS.
    Regards
    Vinod

  • My iPhone mobile set got damaged. Got a replacement. Need to recover my data from the last iPhone mobile device. How to do the needful?

    iPhone got damaged
    got a new set as replacement
    all data is lost
    how to recover the data?

    When setting up the new one, you need to restore it from a backup of the old one.
    If you had iOS 5 on your old one:
    Your new phone should also have iOS 5, so on the setup screens, wait until you get to the menu that allows you to select "Restore from iCloud Backup."
    If you did not have iOS 5 on your old one:
    You can plug in the new phone to iTunes, select Restore. Let it do it's thing, and when it's done, select Restore from Backup.

  • Need to fill up Data into  the select Tag options value

    Hi ,
    This is my requirement . I am having two select tags inside my jsp page . one for country and one for state .Upon selecting a country the select tag for states should be filled up .
    Right now i need to fill up the data under country select Tag .I am using AJAX for this .On body onload i am calling a function to get Country data .
    //This is inside my servlet
    *               ResultSet res = st.executeQuery("SELECT * FROM countries );*
    *               StringBuffer sb = new StringBuffer();*
    *     sb.append("<countries>");*
    *               while (res.next())*
    *               String result = res.getString(1);*
    *               sb.append("<country>"+result+"</country>");*
    *               sb.append("</countries>");*
    *               response.getWriter().write(sb.toString());*
    This is Inside MY JSP
    if( xmlHttp.readyState==4 )
    if( xmlHttp.status==200 )
    xmlDoc=xmlHttp.responseXML;
    xmlDoc.getElementsByTagName("countries")
    <select name='countrsel' id="countrsel" onchange="call()">
    <option value="<%=%>"><%=%></option>
    </select>
    I am struck up here please help
    Edited by: RaviKIran on Nov 2, 2009 9:51 AM

    Hi ,
    This is my requirement . I am having two select tags inside my jsp page . one for country and one for state .Upon selecting a country the select tag for states should be filled up .
    Right now i need to fill up the data under country select Tag .I am using AJAX for this .On body onload i am calling a function to get Country data .
    //This is inside my servlet
    *               ResultSet res = st.executeQuery("SELECT * FROM countries );*
    *               StringBuffer sb = new StringBuffer();*
    *     sb.append("<countries>");*
    *               while (res.next())*
    *               String result = res.getString(1);*
    *               sb.append("<country>"+result+"</country>");*
    *               sb.append("</countries>");*
    *               response.getWriter().write(sb.toString());*
    This is Inside MY JSP
    if( xmlHttp.readyState==4 )
    if( xmlHttp.status==200 )
    xmlDoc=xmlHttp.responseXML;
    xmlDoc.getElementsByTagName("countries")
    <select name='countrsel' id="countrsel" onchange="call()">
    <option value="<%=%>"><%=%></option>
    </select>
    I am struck up here please help
    Edited by: RaviKIran on Nov 2, 2009 9:51 AM

  • I need to load weather data from the internet using ODI

    Hi,
    I need to populate my weather table from the internet, however i am not sure where to start from.
    Anybody had done this before, any ideas, recommndation and suggestion
    TIA
    Shawn

    Hi Venkat,
    I have this url link that has historical temperatures ready and i want to populate my oracle table with the reading using odi. The like is http://www.wunderground.com/history/airport/OLBA/2011/5/1/MonthlyHistory.html?req_city=NA&req_state=NA&req_statename=NA&MR=1&format=1
    In ODI I tried the Physical Architecture XML and defined a new Data Store and selected JDBC driver com.sunopsis.jdbc.driver.xml.SnpsXmlDriver and in the JDBC URL
    jdbc:snps:xml?f=http://www.wunderground.com/history/airport/OLBA/2011/5/1/MonthlyHistory.html?
    I tried testing the connections I get a "Connection Failed" however, if i put the url in a browser it displays the content.
    I am going about correctly or is there a correct way to it?
    Thanks
    Hicham

  • What's the lifecycle of Global Data in Function Group?

    Hello,
    I thought the Global Data in function group will be cleaned for each call stack. While it seems not so.
    With a BSP web application, it seems the global data of the function group would persist untill the session times out.
    I didn't find exact description regarding this. Could anybody help clarify this? For web session and SAPGUI session.
    Thanks and regards,
    Said

    hi,
    based on my understanding of the global data in the funtion group, let's say, when you call a FM a in FG b,  all of the content in the FG b is loaded into the stack. so the global data is cleaned after your program or transaction is complete.  but this will not happen when the called FM is finished, coz when you call a FM , the whole FG is loaded, so if you call FM c in FG b after you callling FM a, your program will not load the whole FG again.

  • Combo Box Use Global Data issue

    I am using a drop down combo box to select a name, and have checked specifiy item values, am using the item numbers in a switch statement to populate other text boxes depending on selection of drop down.  These same items appear several times in the form, so am setting them to use global data.  All work great except for the textboxes bound using global data to the drop down.  In those results, it's putting the item number, not the text value.  How do I get the text value to show instead of the item value?  Thank you!

    Resolved it by changing the switch statement to use the text value instead of item number, and unchecked the specify item values in the combo box.  I would be interested for future use to learn how to do this, but no worries if not.  At least the form is operating the way it needs to.  Thanks.

  • How to delete entire data in the hierarchy table,?

    hi friends
    i need to delete entire data in the hierarchy table which contains parent child relationship,when i am selecting entire records and choose the option delete from the context menu, it is not deleting, and i have to delete one by one or i have delete first the child items and later parents items, it is time consuming process.
    Is there any other option to delete entire records in the hierachy table , irrespective of parent and child relationship?
    if any one have solution for my issue, please provide to me
    thanks in advance
    bharat.chinthapatla

    Hi Bharat,
      Unload the Repository and Delete the Table and fields in Hierarchy table and Recreate and reload the data.OIther wise you have to lot of manual work.
    Thanks
    Ganesh Kotti

Maybe you are looking for

  • Mail attachment issues in full screen apps

    This is an interesting issue.  So far it only occurs with MS Excel.  When Mail is open as a full screen app and I open an xlsx file attached to a mail message the screen shifts back over to the desktop screen as it should, but the Excel window remian

  • When I add my composition to the Adobe Media Encoder from After Effects, it renders out incorrectly?

    Why is it that when I add my composition directly from after effects to the adobe media encoder, it renders out of the adobe media encoder incorrectly? By that I mean the video comes out a little scrambled- parts of it overlap other parts. Is this an

  • Zen Micro Photo- Stuck in Recovery + ot

    I used my Micro on Thursday, no problem. Went to use it on Monday and it was dead...figured I left it on repeat and the battery died, so Irecharged it. Well, still had minor problems (very slow response of unit) so I reformatted the player and everyt

  • IDevice, HDMI & Underscan

    Hi! When mirroring an iDevice on a TV or projector using the lignthing to HDMI adapter, the image is always scaled down and displayed in the center of the screen with black bars added all the way around. This is *not* an aspect ratio related problem

  • Executable file for IMAQ VIs

    Hi friends,                  I am back here after a long gap. Now I am again in full time research and using LabVIEW as the programing platform as usual. I am working on image processing and have designed a code recently for a small image analysis pu