Import/export to memory and global variables

Hi,
Im working on some functionality using import/export to memory. One of the statements is:
import gf_memid_exit = g_exit_flag gf_memid_result = t352r from memory id 'ZREV_EXT'.
Im using global variables to contain the cluster names. But this is not working. When I change the global variables into local variables, it works. It this normal? Because I would like to have global variables (even better I would like to have global constants) to declare in order to use them within the program.
Any ideas?
With regards,
Mike

Hi Mike...
I think with import u can use global or local variables..in debug mode pl. check when u r using global variables..whether it is getting cleared or overwritten by some other values or not. Or try with global constants..it should work...
Regards,
Joy.

Similar Messages

  • Memory Limit for "IMPORT/EXPORT from MEMORY ID" statement

    Hi All,
    Can anyone tell me whether there is any memory limit exists for "IMPORT/EXPORT from MEMORY ID" statement.
    Like may be we can transfer xx MB of data via this......or it is open, we can transfer any amount of data to ABAP memory via this.
    Regards
    Munish Garg

    1. Each user sessions have external sessions and each external sessions have internal sessions.
    2. The programs being executed in the internal sessions can access ABAP memory
    3.ABAP memory is a storage area for internal program variables like fields, structures, internal tables,,They can be passed  between internal sessions of an external session.
    4. you can transfer data through ABAp memory using IMPORT and EXPORT statements
    5. after IMPORT FROM MEMORY ID <id> , you can use sy-subrc to check the existance of the cluster ID. here sy-subrc is not used to check whether the Import was successful or not.

  • Local and global variables in ABAP Debugger

    hi guys.
    we have the following support package:
    SAP_BASIS     640     0025     SAPKB64025     SAP Basiskomponente
    I would like to use in the debugger the local and global variables tab strip, but I can not find it. Is it possible. that our support package is too low for this functionality?
    Thanks a lot.
    rudit
    Edited by: Rudolf Tremmel on Aug 17, 2010 8:35 AM

    Starting with SAP NetWeaver 6.40, SAP released a new version of the Debugger.
    The Debugger available in Release 6.40 was not considered complete (and was
    not the default debugger as a result)
    The Variable Fast Display tool currently has four tabs . The first
    two are provided empty, and you can either type or double click a name in the
    source code to add it to the list. The third tab (Locals) shows all local variables
    for the current program modularization unit, and the fourth (Globals) shows all
    global variables in the current program.

  • How can we use IMPORT-EXPORT as structure and TABLES parameters?

    Hello Sir,
    I have used SAPRFC with single IMPORT and EXPORT parameter.
    Could anybody give me an example in I can use IMPORT/EXPORT as structure and TABLE parameter as input?
    of course from/to PHP.
    Regards,
    RH

    Thanks

  • What is the difference between Instance variable and Global variable?

    Hi folks,
    Could you please explain me, "what is the difference between Instance variable and Global variable?"
    Are they really same or not?
    --Subbu                                                                                                                                                                                                                                                                                                               

    Hi flounder,
    I too know that there is no such a term GLOBAL in java.
    generally people use to say a variable which is accessible throught out the class or file has global access
    and that will be called as a global variable...
    my point is very much similar to what Looce said.
    In simple that is not a technical term, but just a causual term.
    In technically my question is, "What is the difference between a instance variable and public variable?".
    Hi looce,
    Thanks for the reply. even thats what my understanding too....in order to confirm that i raised this question..
    Your reply has given a clear answer...... thanks again.
    --Subbu                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

  • Shared and Global Variable Issue with Motor VI

    Hello,
    I have written a VI that will command a stepper motor to follow the desired profile and loop the profile until the user pushes the stop button. I modified the state machine example from LV to achieve this. I now want to connect a linear potentiometer to the linear actuator to verify that the distance I commanded the motor to travel is the actual distance that it traveled. I am using a NI 9219 module to collect the data from the potentiometer.
    When I added the potentiometer to the program, the cRIO-9073 chassis that I am using immediately crashes and looses connection with the computer when I click the Run VI button. I looked into this a little more and it seems that the chassis will crash only when I add shared and global variables to the VI. I think it has something to do with the Network Variable Engine; I don’t have it installed on the chassis because the motor program alone will not run if it is installed on the chassis. Also, I have the chassis configured to the RT setting and not the FPGA setting.
    I have attached a snippet of the code. I am using LV 2014 SP1 along with the SoftMotion module. The motor is connected to LV through a P70530 stepper drive which is connected to a NI 9512 module with the proper connectivity bundle. Is there something wrong with the VI that would cause the chassis to crash? Why will the simple motor VI not work when the Network Variable Engine is installed on the chassis? Thank you in advance for your help!

    Follow up to this post:
    Sometimes when I try to connect the project to the chassis I get the following error: "Failed to load shared library taggerrt.out. Ensure that the library is present on the RT target. Use either MAX to install NI software or FTP to transfer custom librarier to the RT target."
    I have tried re-installing the NI Device Drivers and reconfiguring the software on the cRIO chassis using MAX; however, the error keeps showing up. I read somewhere that the taggerrt.out library is a part of the Network Variable Engine but I don't know why it wouldn't be found when the NVE software is installed on the chassis. This message only comes up when I also have the SoftMotion Module software installed on the chassis. Has anybody else encountered this problem or know why this could be happening? Any ideas would be greatly appreciated! Thanks!

  • ME22n - doubt in IMPORT/EXPORT in EXIT_SAPMM06E_013 and EXIT_SAPMM06E_012

    hi
    i need to validate a condition in EXIT_SAPMM06E_013 and accordingly i need to populate the error msg in EXIT_SAPMM06E_012 while saving and stop the PO posting.
    in ZXM06U44 in EXIT_SAPMM06E_013 i have written the code
    IF sy-mandt = 888.
      DATA: gv_check TYPE xfeld.
      DATA: itab TYPE STANDARD TABLE OF uekes,
      wa TYPE uekes.
      IF sy-tcode = 'ME22N' OR
         sy-tcode = 'ME22'.
        LOOP AT xekes.
          IF xekes-ebtyp = 'LA' AND
             xekes-vbeln = space.
            gv_check = 'X'.
            EXIT.
          ENDIF.
        ENDLOOP.
        IF gv_check = 'X'.
          EXPORT gv_check = 'X' TO MEMORY ID 'A123'.
        ENDIF.
      ENDIF.
    ENDIF.
    i am exporting the variable and importing in the below exit.
    in ZXM06U43 in exit EXIT_SAPMM06E_012  i have written the code
    IF sy-mandt = 888.
      DATA: gv_check TYPE xfeld,
      IF sy-tcode = 'ME22N' OR
         sy-tcode = 'ME22'.
        IMPORT gv_check FROM MEMORY ID 'A123'.
        IF gv_check = 'X'.
          MESSAGE e000(z1) WITH 'No manual LA Allowed'.
        ENDIF.
      ENDIF.
    ENDIF.
    but the value is not getting imported and actually when i press the save button, the EXIT_SAPMM06E_012  is called first and then goes to EXIT_SAPMM06E_013 and my PO gets saved.
    how to solve this issue.
    Regards,
    Sakthi.

    Why do you want to do validation in EXIT_SAPMM06E_013 and err message in EXIT_SAPMM06E_012?
    Do an validation in EXIT_SAPMM06E_013 FM itself.
    the below statement is wrong
    EXPORT gv_check = 'X' TO MEMORY ID 'A123'.
    gv_check  = 'X'.
    EXPORT gv_check TO MEMORY ID 'A123'.
    Regards,

  • Problem with .DLL and global variables

    Hi,
    I need some helps to figure out my problem.
    I wrote a .dll file to open and run a GUI. When I run it at the first time, it is ok. When I call it again, there is an error "Pointer to free memory passed to library. It will be ok if I completely exit the program that calls the .dll before re-call it. I think there is some problems with global variables when I call another thread. How can I free global variables between threads. Is there any solution for this problem?
    Thanks

    Vinh Pham:
    Are you doing anything intentionally that frees your globals?
    CVI ships with an example program that demonstrates calling a DLL to create a user interface: guidll.cws.
    I made two simple modifications to guidll.cws.
    1. In guidll.c, I made hpanel global by moving its declaration from RunDLLUI() to right below the #include statements.
    2. In useguidll.c, I duplicated the lines calling RunDLLUI () and MessagePopup() to call the DLL gui twice.
    I built the project and ran it.  I had no problems with free'ed globals.
    Take a look at the guidll example.
    Can you either post your code or a modification to guidll that demonstrates the problem you're having?

  • ECC6 IMPORT/EXPORT to MEMORY ID 'OPENFI00002213E'

    Hi experts,
    I have a problem with IMPORT/EXPORT in ECC6 within the same program. The short dump happenned at IMPORT time. Here is part of my code.
    DATA: MEMID13(15) VALUE 'OPENFI00002213E',
              T_VBKPF  LIKE  VBKPF OCCURS 0 WITH HEADER LINE.
    EXPORT t_vbkpf TO MEMORY ID memid13.
    CALL TRANSACTION 'FV60'
         USING bdcdata
         OPTIONS FROM s_ctu_params
         MESSAGES INTO bdcmsgcoll.
    IMPORT t_vbkpf FROM MEMORY ID memid13.
    In 4.6C, the internal table t_vbkpf was updated with the created document from the transaction 'FV60' call but it gave a short dump in ECC6.
    Runtime Errors         CONNE_IMPORT_WRONG_STRUCTURE                  
    Except.                CX_SY_IMPORT_MISMATCH_ERROR                   
    Date and Time          2007.12.06 15:46:46                           
    Short text                                                          
         Error when importing object "T_VBKPF".                                                                               
    Please help, thanks!
    CHuong

    Hi,
    In ECC 6 for import from memory you need the import structure will be flat , character-type data
    The following is from documentation.
    +
    If MEMORY is specified, the data cluster that was written to the ABAP Memory under the identification specified in id with the statement EXPORT is imported. For id, a flat , character-type data object is expected. This object contains the identification of the data cluster.
    +
    otherwise use this way
    TYPES:
      BEGIN OF tab,
        col1 TYPE i,
        col2 TYPE i,
      END OF tab.
    DATA:
      wa_indx TYPE indx,
      wa_itab TYPE tab,
      cl      TYPE mandt VALUE '100',
      itab    TYPE STANDARD TABLE OF tab.
    IMPORT tab = itab
      FROM DATABASE indx(xy)
      TO   wa_indx
      CLIENT cl
      ID 'TABLE'.
    WRITE: wa_indx-aedat, wa_indx-usera, wa_indx-pgmid.
    ULINE.
    LOOP AT itab INTO wa_itab.
      WRITE: / wa_itab-col1, wa_itab-col2.
    ENDLOOP.

  • DASYLAB QUERIES on Sampling Rate and global variable

    hola
    i'm new user of dasylab and i would like to manipulate the sample rate through a layout ;
    using global variable seems good idea but the adress of sample rate is unknown .
    Hope that someone would be able to help.!
    also other small things when i use coded swich and i want modify  the text in the Switch Window i don't know how
    Lots of thanks!

    Hi,
    There is a dedicated place in this forum where you'll certainly get more answers than here :
    http://forums.ni.com/t5/DASYLab/bd-p/50
    Regards,
    Da Helmut

  • Forms personalization and global variable

    Hi,
    I'm trying to call a procedure in forms personalization and using a defined global variable. The data in the global variable is number. In the procedure, some of the parameter has a number datatype and I'm converting the global variable using to_number eg (to_number(:global.XX_LINE_NUM). This fails with error message ora-01403 no data found. I've tried putting the above into a variable with datatype number in the declare statement, and it errors as well.
    Does anyone knows the syntax to convert the global variable to number datatype in personalization.
    Thanks

    Ask in this forum : OA Framework

  • Function REUSE_ALV_GRID_DISPLAY, events and global variables

    Hi everybody,
    in a report I use FM REUSE_ALV_GRID_DISPLAY with a registered callback for event 'USER_COMMAND'.
    In the callback-form I want to change the internal table, which I provided for displaying to REUSE_ALV_GRID_DISPLAY.
    How can I access the internal table in the callback-form without using global variables?.
    Kind regards,
    Hubert
    Edited by: Hubert Heitzer on Feb 23, 2011 4:13 PM
    This is not the solution I asked for, but I found a workaround.
    I created a function group, which encapsulates the internal table.
    A function provides the service for colleting data for the internal table and displays the ALV.
    The callback-form is also a member of my function group and is therefore able to access the internal table.

    Hi everybody,
    in a report I use FM REUSE_ALV_GRID_DISPLAY with a registered callback for event 'USER_COMMAND'.
    In the callback-form I want to change the internal table, which I provided for displaying to REUSE_ALV_GRID_DISPLAY.
    How can I access the internal table in the callback-form without using global variables?.
    Kind regards,
    Hubert
    Edited by: Hubert Heitzer on Feb 23, 2011 4:13 PM
    This is not the solution I asked for, but I found a workaround.
    I created a function group, which encapsulates the internal table.
    A function provides the service for colleting data for the internal table and displays the ALV.
    The callback-form is also a member of my function group and is therefore able to access the internal table.

  • Web Services: runBatchJob and global variables

    Dear all,
    I'm facing a problem when I try to call web method runBatchJob defined by port BatchJobAdmin of the Web Service interface published by DS. 
    I have defined a job TestWSCall characterized by global variable $G defined as varchar(50) and I have written the following code to invoke job  TestWSCall with variable $G set to a given value (e.g. u2018Testu2019):
    RunBatchJobRequest runBatchJobRequest = new RunBatchJobRequest();
    runBatchJobRequest.setJobName(jobNameCall);
    runBatchJobRequest.setRepoName(repoName);
    GlobalVariables variables = new GlobalVariables();
    Variable gvariable=new Variable();
    gvariable.setName(varName);
    gvariable.setValue(varValue);
    variables.getVariable().add(gvariable);           
    runBatchJobRequest.setGlobalVariables(variables);
    BatchJobResponse res = batchJobAdmin.runBatchJob(runBatchJobRequest);
    After running this code, the job is executed with the default value and not with value u2018Testu2019. Since the variable type is varchar, I've also tested with value Test written between '', but it is ignored as well.
    When I check the XML generated by my call, I obtain the following XML code:
    <globalVariables><variable name="$G">'Test'</variable></globalVariables>
    or without ''
    <globalVariables><variable name="$G">Test</variable></globalVariables>
    which seems to comply with the description provided by the WSDL.
    Notice that job TestWSCall (and in particular the value of variable $GVAR) works as expected when I launch it from Designer or the web interface.
    Any idea?

    Hi,
    I have done the same scenario as you.
    For e.g.
    If your global variable is $gv, then your java code would be use gv as the global variable name (without the $)
    You would also emit the '' from the value in the global variable text.

  • FixValues and Global Variable

    hi,
    Is there a functionality which does exactly like FixValues but stores the value thorugh out the mapping?
    I have a requirement where i have to map 2 different values to other values but i have to repeat this for all the fields using FixValue instead if there would be a Global Variable i could use that instead.
    Any ideas.
    Thanks,
    KP

    Hi Tirumal,
    For your requirement you can define a HashMap in Java Sections Tab of Graphical mapping and refer the values from UDF.
    Steps
    1. Goto MessageMapping (Design TAB)-> Edit JAVA Sections (Found on top-right side)
    2. Declare a HashMap in Global variables section.
        Eg.
    HashMap materialNumMap = null;
    3. Initialize the same variable and fill some values.
        Eg.
    materialNumMap = new HashMap();
                materialNumMap.put("MAT-01","10001");
                materialNumMap.put("MAT-02","10002"); 
                materialNumMap.put("MAT-03","10003");
                materialNumMap.put("MAT-04","10004");
    4. Write UDF to retrieve value from Global container
    public void chkExists(String materialNUM,ResultList result,Container container){
      String valueFrmMap = (String)materialNumMap.get(materialNUM);
      return valueFrmMap;
    Hope this solves your problem.
    Regards,
    Ananth

  • DTEXEC and Global Variable

    Hi,
    I have written a stored procedure where I want to call/execute a DTSX. In SQL2000 this was possible using DTSRun /A [GlobalVariable]=[Value] . How to in SQL2005 (DTEXEC /[?] , what is the parameter for the ? for a global variable?
    Thx for your help,
    Johan

    Found the answer, it should be:
    /Set PropertyPath;Value
    Thx for looking into it (if you did)!
    Ps: if you have more info, please let me know anyway

Maybe you are looking for