Using set/get parameters or export/import in BSP.

Hi All,
Is it possible to use set/get or export/import in BSP?
We need to set/export some variables from a BADI and get/ import them in the BSP application.
Code snippet will be of great help..
Thanks,
Anubhav

Hi Anubhav,
You can use the Export / Import statements for your requirement,
from the BADI use EXPORT to send the variable data to a unique memory location
with IDs
e.g.
*data declaration required for background processing
      DATA: WA_INDX TYPE INDX.
**here CNAME is the variable you want to export
EXPORT PNAME = CNAME TO DATABASE INDX(XY) FROM WA_INDX CLIENT
            SY-MANDT ID 'ZVAR1'.
and in the BSP application use the IMPORT statement to fetch back the values
set with the IDs above.
IMPORT PNAME = LV_CNAME
  FROM DATABASE INDX(XY) TO WA_INDX CLIENT
  SY-MANDT ID 'ZVAR1'.
deletes the data to save wastage of memory
  DELETE FROM DATABASE INDX(XY)
    CLIENT SY-MANDT
    ID 'ZVAR1'.
Regards,
Samson Rodrigues

Similar Messages

  • Using SET GET parameters in ITS

    Hi All,
    Is it possible to use set get parameters in ITS. We want to set some parameters in a BADI and read the value in ITS Template .
    Or is there any other method to do this?
    Thanks,
    Anubhav

    Sure. In your abap program use the following code
    *  ITS macros
    INCLUDE avwrtcxm.
    GET PARAMETER ID 'YOUR_PARAMETER' FIELD SAVE_PARAMETER.
    field-set u2018~YOUR_PARAMETERu2019 1 SAVE_PARAMETER.
    field-transport.
    in the template you can now use ~YOUR_PARAMETER.
    regards,
    Klaus
    Edited by: Klaus Layer on Feb 3, 2009 5:05 PM

  • How to use SET & GET Parameters in Module Pool

    Hi Friends,
    Can anyone please tell how to use SET / GET parameters and PARAMETER ID for a text box (Input / Output field ) in module pool? What is the purpose and where do we need to do coding for it?
    Note : I will definitely give the marks for good responses.
    Thanks in advance,
    Pradeep

    Hi Pradeep,
    You can save values in the SAP memory using a parameter ID. These
    are user and terminal-session specific, but available to all internal and
    external sessions.
    SET Parameter copies the corresponding field contents into the SAP
    System memory in the PAI processing block.
    GET Parameter copies the corresponding field contents from the SAP
    memory at the end of the PBO processing block, after data has been
    transferred from the program, if the screen field still has its initial value
    You can link an input/output field to an area of the SAP memory in the
    ABAP Dictionary.
    When you use an input/output field that is defined in the ABAP
    Dictionary, its parameter ID is displayed in the Dictionary attribute
    Parameter ID in the Screen Painter.
    Usage
    SET PARAMETER ID: ’CAR’ FIELD space,
    ’CON’ FIELD space,
    ’DAY’ FIELD space.
    Here is the link that explains the usage of GET/SET in detail
    <a href="http://help.sap.com/saphelp_erp2005vp/helpdata/en/9f/db9e0435c111d1829f0000e829fbfe/content.htm">http://help.sap.com/saphelp_erp2005vp/helpdata/en/9f/db9e0435c111d1829f0000e829fbfe/content.htm</a>
    Regards,
    Sharadha

  • Problem with SET GET parameters

    Hi all,
    I am facing a problem using SET and GET parameters.
    There is a Z transaction(Dialog program) where some fields of screen are having parameter ID's. That transaction is designed to diaplay/change status of only one inspection lot at a time.
    Now I need to call that transaction in a loop using BDC. I mean i need to update the status of multiple inspection lots(one after the other). Before calling the transaction I am using
    SET PARAMETER ID 'QLS' FIELD lv_prueflos.
    Unfortunately the transaction is only changing the first inspection lot. When I debugged I found that the screen field is changing in PAI. Even though in PBO it shows the next value, when it goes to PAI it is automatically changing to the first value(inspection lot).
    Example: Inspection Lots : 4100000234
                                               4100000235
                                              4100000236
    Now first time when the call transaction is being made the status of insp lot 4100000234 is changed. For the second time when insp lot 4100000235 is being passed in PBO ican see this. But the moment it enters PAI the screen field changes to 4100000234.
    Could you pls help me in solving this issue.
    Thanks,
    Aravind

    Hi,
    Problem with SET GET parameters
    Regarding on your query. Follow this below link.
    It will help you.
    Re: Problem with Set parameter ID
    Re: Problem in Set parameter ID
    I Hope it will helps to you.
    Regards,
    Sekhar

  • Can I use create a job to export/import?

    I want to export database on regular basis, is there a way to do that by a job? If yes, how?
    Thanks in advance.

    A few reasons-
    By default, exports are not transactionally consistent, so you can end up with children records, for example, that point to parents that don't exist in the export file. You can set consistent=y when you export, but that requires a lot of rollback if people are using the database at the time.
    If you are doing exports as your sole means of backup, everything since your last export is at risk-- if there is a failure, you will lose that data. Generally, you want to be able to recover a production database without the loss of any committed data.
    If you are using exports, you cannot restore the database to a point in time (other than when the database was last exported).
    Exports do not scale very well. If you are doing hot backups, you can back up only incremental changes. If you are exporting, you have to get everything or nothing. As the database size grows, exports get more and more expensive and take longer and longer to run.
    Justin
    Distributed Database Consulting, Inc.
    http://www.ddbcinc.com/askDDBC

  • Data migration from one DEV(DE1) system to other DEV(DE2) BW system using client copy or client export import

    HI SAP Gurus,
    Please find the below details:
    SAP NetWeaver 7.3
    We have to copy all customized or developed BW objects like master data, DSO's , Infocubes , Reports etc.
    We need only the design changes but not the data within the DSO or cubes that exist .
    We have tried below procedure:
    1) Taken export of DE1 source client 400 with profile SAP_CUST
    2) Imported transports generated for above export into DE2 target client 350.
    3) Executed transaction SCC3 and performed post processing, post processing was successful  . Still we are not able to see DSO's, infocubes ,reports.
    Please lets us know what we need to do to fulfill our requirement.
    Thanks,
    Avadhesh
    + 91 8095226536

    Hi Basis,
    Please refer to below documentation on how to perform system copy in BI systems
    How to System Copy in SAP Business Intelligence System Landscapes (NW2004)
    Post processing steps for SAP BW system copy or db copy
    BI systems has mostly cross client objects. So client copy with SAP_CUST profile will not serve your purpose.
    Hope this helps.
    Regards,
    Deepak Kori

  • SUBMIT program VIA JOB and SET/GET parameter

    Hi All
    I need to pass the content of a variable from the program 'A' to program 'B'.
    Program A uses JOB_OPEN , SUBMIT program VIA JOB jobname NUMBER jobnumber AND return, JOB_CLOSE.
    I tried to use import/export memory but it didn't work. Then I am trying to use set/get parameters but it also did not work.
    Program A is going to run in any server and program B will run in the central instance (it is determined in the FM JOB_CLOSE, parameter target_server).
    Program does not have selection-screen.
    Is it possible use set/get parameter with submit via job?
    Could you please advise?
    Thanks in advance.
    João Gaia

    Here a simple code
    *Submit report as job(i.e. in background)
    data: jobname like tbtcjob-jobname value
                                 'TRANSFER DATA'.
    data: jobcount like tbtcjob-jobcount,
          host like msxxlist-host.
    data: begin of starttime.
            include structure tbtcstrt.
    data: end of starttime.
    data: starttimeimmediate like btch0000-char1 value 'X'.
    * Job open
      call function 'JOB_OPEN'
           exporting
                delanfrep        = ' '
                jobgroup         = ' '
                jobname          = jobname
                sdlstrtdt        = sy-datum
                sdlstrttm        = sy-uzeit
           importing
                jobcount         = jobcount
           exceptions
                cant_create_job  = 01
                invalid_job_data = 02
                jobname_missing  = 03.
      if sy-subrc ne 0.
                                           "error processing
      endif.
    * Insert process into job
    SUBMIT zreport and return
                    with p_param1 = 'value'
                    with p_param2 = 'value'
                    user sy-uname
                    via job jobname
                    number jobcount.
      if sy-subrc > 0.
                                           "error processing
      endif.
    * Close job
      starttime-sdlstrtdt = sy-datum + 1.
      starttime-sdlstrttm = '220000'.
      call function 'JOB_CLOSE'
           exporting
    "            event_id             = starttime-eventid
    "            event_param          = starttime-eventparm
    "            event_periodic       = starttime-periodic
                jobcount             = jobcount
                jobname              = jobname
    "            laststrtdt           = starttime-laststrtdt
    "            laststrttm           = starttime-laststrttm
    "            prddays              = 1
    "            prdhours             = 0
    "            prdmins              = 0
    "            prdmonths            = 0
    "            prdweeks             = 0
    "            sdlstrtdt            = starttime-sdlstrtdt
    "            sdlstrttm            = starttime-sdlstrttm
                strtimmed            = starttimeimmediate
    "            targetsystem         = host
           exceptions
                cant_start_immediate = 01
                invalid_startdate    = 02
                jobname_missing      = 03
                job_close_failed     = 04
                job_nosteps          = 05
                job_notex            = 06
                lock_failed          = 07
                others               = 99.
      if sy-subrc eq 0.
                                           "error processing
      endif.
    Then... for import/export of a variable, you can use Import Memory and Export Memory function.
    Like this:
    REPORT A:
      IF NOT it_dlist_out IS INITIAL.
        EXPORT it_dlist_out TO MEMORY ID 'TEST1234'.
      ELSE.
    * Clearing memory
        FREE MEMORY ID 'TEST1234'.
      ENDIF.
    REPORT B:
    IMPORT it_dlist_out TO lt_dlist_out FROM MEMORY ID 'TEST1234'.
    Edited by: spantaleoni on Jan 11, 2011 3:21 PM
    Edited by: spantaleoni on Jan 11, 2011 3:23 PM

  • Export/import to/from database

    hi,
    i do not know what is this for. i read the help but still no idea.
    i know to use export/import to/from memory id and also set/get but not export/import to/from database.
    1) what help says it stores data cluster? what is data cluster
    2) can have example of export/import to/from database?
    3) what is the different for export/import to/from memory id and database?
    thanks

    Hi,
    1) A data cluster is a set of data objects grouped together for the purpose of storage in a storage medium(Like database, local memory or shared meomory etc), which can only be edited using ABAP statements like EXPORT, IMPORT and DELETE.
    2) Suppose you want to export the data in a internal table to database.
    Here TABLE_ID is the identifer of your data cluster. You are exporting your data to a SAP table INDX and giving it an ID (TABLE_ID in this case and this ID you are giving it an area by name XY where your data will be stored). EXPORT tab = itab
      TO DATABASE indx(XY)
      CLIENT '000'
      ID 'TABLE_ID'.   
    You can get this data as follows.
    IMPORT tab = itab
      FROM DATABASE indx(xy)
      CLIENT '000'
      ID 'TABLE_ID'.
    3) The difference is simple when you use MEMORY ID the data you export is stored in the application server MEMORY where as in the case of DATABASE it is stored in the database.
    Regards,
    Sesh

  • How to set/get URL-parameters from ORACLE -tag?

    How do I set/get parameters in a URL, using the <ORACLE>-tag?
    We are trying to create a UI Template containing a dynamic
    stylesheet selection dialogue on top of every page. The question
    we are facing now is how to pass parameters (in our case,
    stylesheet settings) between different pages.
    Any ideas/comments are appreciated!

    How do I set/get parameters in a URL, using the <ORACLE>-tag?
    We are trying to create a UI Template containing a dynamic
    stylesheet selection dialogue on top of every page. The question
    we are facing now is how to pass parameters (in our case,
    stylesheet settings) between different pages.
    Any ideas/comments are appreciated!

  • Issues with Export/Import using Database & Shared buffer

    Hi All,
    I have a method that calls a program via a job and I am having issues passing data between the two.
    Note that two different users process the method and program (via job) resp. This is how I am calling the second prog-
    SUBMIT ZPROGRAM
                 VIA JOB     l_jobname
                     NUMBER  l_jobcount
                     USER    i_user
                 AND RETURN.
    I need to pass data from method to  the second program and vice versa and then the method continues its processing with the data acquired from the second program.
    I have tried using Import/Export using database and also shared buffer. What I have found is that most of the times I am able to pass data from method to program. However the job takes a couple of min to execute and I think that the data is not making back to the method in time.
    I have looked at some useful forum links-
    Problem with export/import in back ground
    Re: EXPORT/IMPORT  to MEMORY
    but havent been able to find an answer yet. Any solution? Thanks in advance for your help!
    Liz

    Hi Suhas, Subhankar
    I have tested the scenario without the job previously itself and it works. Thats the reason, i am trying with the job now as my requirement is that I need to change the user while executing the second report.
    Here is an example of my import/export - I am passing the return value from the second report to the first.
    Code in second report-
    DATA: INDXKEY LIKE INDX-SRTFD VALUE 'RET1'.
    INDX-AEDAT = SY-DATUM.
    INDX-USERA = SY-UNAME.
    EXPORT RETURN1 TO SHARED BUFFER INDX(ST) ID INDXKEY.
    Code in first report -
    SUBMIT ZPROGRAM
                     VIA JOB     l_jobname
                         NUMBER  l_jobcount
                         USER    i_user
                     AND RETURN.
    Once Job close FM is executed successfully, I import the values as follows
    IMPORT RETURN1 TO RETURN1 FROM SHARED BUFFER INDX(ST) ID INDXKEY3.
    INDXKEY is having value RET1.
    However Return1 is not having any values in first report. It has some value in executed without the job
    Please note that I have tried Export/import with Database too and I am getting the same results.
    Thanks for your suggestions.
    Regards, Liz

  • Using package to export & Import data

    Hi!
    Now i'm using exp imp utility to export & import data, but i don't want to everybody know password. My platform is windows 2000.
    I want know, there is a package to do this?
    thank!

    What version of Oracle do you have? If you're on 10.1 or later, the DataPump versions of export and import use the DBMS_DATAPUMP package to do exports & imports. You should be able to use those to run the export from within a database session.
    If your concern relates to people discovering database passwords from the BAT file you're using to invoke the export & import utilities at the command line, you might also consider using externally authenticated users. If you are logged in as a member of the ORA_DBA group, for example, you can connect to Oracle without a password
    sqlplus / as sysdbaJustin
    Distributed Database Consulting, Inc.
    http://www.ddbcinc.com/askDDBC

  • SET/GET not working when I submit one program into Main program.

    Hi All,
    I am using set/get parameter as follows but somewht it is not working.. Please help.
      IF ( uf_instn = 'ACEFR' and uf_messg <> 'BSP' ).
        set parameter id 'AJN' field lf_jobname.
        set parameter id 'AJC' field gf_jobcount.
      ENDIF.
      SUBMIT   zace_interface
        USER   sy-uname
        VIA    JOB lf_jobname
        NUMBER gf_jobcount
        WITH   SELECTION-TABLE lt_seltab
      TO     SAP-SPOOL
        AND    RETURN.
    in the zace_interface program I have another submit program
        submit zrsbdcsub and return
                        user 'ZACE_INTERFACE'
                        with mappe eq lf_group
                        with von eq sy-datum
                        with bis eq sy-datum
                        with fehler eq space
                        with logall eq co_true.
    ad inside this submit im using
                  get parameter id 'AJN' field v_jobname.
                  get parameter id 'AJC' field v_jobcount.
    but i am not able to get the values into v_jobname & v_jobcount.
    Can you please help me in this regard. how i will get the values in v_jobname & v_jobcount.
    Thanking you in advance
    Regards,
    Prashant

    Hi..,
    any way u r executing the programs in the same session but between diff. internal sessions u can use the IMPORT and EXPORT options ( ABAP MEMORY )
    or do one thing...
    <b>In the first program Copy these fields into a file in the <b>application server</b>,, and in the Second submit program u retrieve these variable values from the Application server file into these two variables!!</b>
    just now i have solved one of the issues of this Kind by using an Application server file.
    In the first program..
    IF ( uf_instn = 'ACEFR' and uf_messg <> 'BSP' ).
    OPEN dataset 'FILE' for output in text mode encoding default.
    transfer lf_jobname to 'FILE'.
    transfer gf_jobcount to 'FILE'.
    CLOSE dataset 'FILE'.
    ENDIF.
    and instead of using the GET parameters in the second program ..
    OPEN dataset 'FILE' for input in text mode encoding default.
    read dataset 'FILE' into v_jobname.
    read dataset 'FILE' into v_jobcount.
    CLOSE dataset 'FILE'.
    This has solved my problem !!!!! hope this helps u also!!
    regards,
    sai ramesh

  • Set get parameter but free memory id is not working

    Hi All,
    I am using set get parameter  to transfer data from one module to another .
    But when i am trying to clear the memory id using Free memory id .
    it is not doing that.
    Does it work with import export.
    What method i should use to clear this memory id ..
    Thanks in advance
    ANit gautam

    Clears the memory:
    SET PARAMETER ID pid FIELD space.

  • Regarding Distribution Monitor for export/import

    Hi,
    We are planning to migrate the 1.2TB of database from Oracle 10.2g to MaxDB7.7 . We are currently testing the database migration on test system for 1.2TB of data. First we tried with just simple export/import i.e. without distribution monitor we were able to export the database in 16hrs but import was running for more than 88hrs so we aborted the import process. And later we found that we can use distribution monitor and distribute the export/import load on multiple systems so that import will get complete within resonable time. We used 2 application server for export /import but export completed within 14hrs but here again import was running more than 80hrs so we aborted the import process. We also done table splitting for big tables but no luck. And 8 parallel process was running on each servers i.e. one CI and 2 App servers. We followed the document DistributionMonitorUserGuide from SAP. I observerd that  on central system CPU and Memory was utilizing above 94%. But on 2 application server which we added on that servers the  CPU and Memory utilization was very low i.e. 10%. Please find the system configuration as below,
    Central Instance - 8CPU (550Mhz) 32GB RAM
    App Server1 - 8CPU (550Mhz) 16GB RAM
    App Server2 - 8CPU (550Mhz) 16GB RAM
    And also when i used top unix command on APP servers i was able to see only one R3load process to be in run state and all other 7 R3load  process was in sleep state. But on central instance all 8 R3load process was in run state. I think as on APP servers all the 8 R3load process was not running add a time that could be the reason for very slow import.
    Please can someone let me know how to improve the import time. And also if someone has done the database migration from Oracle 10.2g to MaxDB if they can tell how they had done the database migration will be helpful. And also if any specific document availble for database migration from Oracle to MaxDB will be helpful.
    Thanks,
    Narendra

    > And also when i used top unix command on APP servers i was able to see only one R3load process to be in run state and all other 7 R3load  process was in sleep state. But on central instance all 8 R3load process was in run state. I think as on APP servers all the 8 R3load process was not running add a time that could be the reason for very slow import.
    > Please can someone let me know how to improve the import time.
    R3load connects directly to the database and loads the data. The quesiton is here: how is your database configured (in sense of caches and memory)?
    > And also if someone has done the database migration from Oracle 10.2g to MaxDB if they can tell how they had done the database migration will be helpful. And also if any specific document availble for database migration from Oracle to MaxDB will be helpful.
    There are no such documents available since the process of migration to another database is called "heterogeneous system copy". This process requires a certified migration consultant ot be on-site to do/assist the migraiton. Those consultants are trained specially for certain databases and know tips and tricks how to improve the migration time.
    See
    http://service.sap.com/osdbmigration
    --> FAQ
    For MaxDB there's a special service available, see
    Note 715701 - Migration to SAP DB/MaxDB
    Markus

  • (ABAP+JAVA) system is too big to export/import

    We have some NW04s and ECC6 dual stack systems that we want to frequently clone using homogeneous system copy method.
    However they can be as big as many terabytes.
    Is there a way to clone they using a way other than export/import?
    Thanks!

    Hi,
    As of SAP NetWeaver 7.0, you can copy ABAPJava systems in one run using either database-specific methods or database-independent methods. In a ABAPJAVA stack system, you need to run a separate export for the Java engine to archive SDM and application specific file contents. You will have to supply that java Export location on the target system, while performing DB specific system copy procedure.
    Please refer [system copy guide for ABAP+JAVA stack |http://service.sap.com/~form/sapnet?_SHORTKEY=01100035870000670917&_SCENARIO=01100035870000000112&_OBJECT=011000358700000416402008E] along with the previously suggested links to get more information.
    Regards
    Bhavik G. Shroff

Maybe you are looking for

  • Problem with a particular stock under default stock app

    When i add a particular stock in the default stock app it does not show the stock details! Stock name is L&T Finance Holdings!! All other stock details are displayed other than the above mentioned one. Please let me know how to sort this out!!

  • I don't want Yahoo on my menu bar. How do I get rid of it?

    How do I get rid of Yahoo on my menu bar? It just appeared and I don't want it. If this is not possible I may have to change to another browser.

  • ITunes sharing not working at all

    I have been trying to set up a LAN so that I can play music from the computer upstairs via my laptop downstairs. At the moment the 2 machines are connected directly with an ethernet cable, so it's not a router problem (every thread I find on this top

  • 2012 R2 logical switch VMQ

    Hey, We are trying to set the correct settings for VMQ on 2012 R2 on our physical servers. Switch settings, Independent mode, Dynamic. CPU, HT 2x12, lp 48. Receive queues is 15 per port, 2x10GB. Per default it sets to base 0, max 16. This seems to wo

  • Probelm in report while running in the background

    Hi all, Iam displaying around 20 fields in in report display. when i execute in the fore ground it is displaying all fields perfectly. but when i run it int he back ground and down load to Excel file its  displaying   5 fields only.(And these 20 fiel