Regarding import and export memory
hi, currently i have encountered this problem when i am using the import and export memory statement. After i export my table name from program1 to program2, i do an import statement at program2 to retrieve the table name but there is a problem in retrieving the name. Below are the codes.
PROGRAM1's codes:
EXPORT IO_TABLE TO MEMORY ID MEM_STR.
SUBMIT PROGRAM2 AND RETURN.
PROGRAM2's codes:
IMPORT IO_TABLE TO MEMORY ID MEM_STR.
P_TABLE = IO_TABLE.
FREE MEMORY ID MEM_STR.
CLEAR MEM_STR.
Check these programs they are working fine, the report ZCALLING calls the report ZCALLED.
REPORT ZCALLING.
DATA:
BEGIN OF IO_TABLE OCCURS 0,
MATNR TYPE MARA-MATNR,
END OF IO_TABLE.
IO_TABLE-MATNR = '38'.
APPEND IO_TABLE.
EXPORT IO_TABLE TO MEMORY ID 'MEM_STR'.
SUBMIT ZCALLED AND RETURN.
REPORT ZCALLED.
DATA:
BEGIN OF IO_TABLE OCCURS 0,
MATNR TYPE MARA-MATNR,
END OF IO_TABLE,
P_TABLE LIKE STANDARD TABLE OF IO_TABLE WITH HEADER LINE.
IMPORT IO_TABLE FROM MEMORY ID 'MEM_STR'.
P_TABLE[] = IO_TABLE[].
LOOP AT P_TABLE.
WRITE P_TABLE-MATNR.
ENDLOOP.
Similar Messages
-
I am having a dought regarding import and export.
I am having a dought regarding import and export.
I am having one table called login_table where 40k rows are present and in production server. Now i want to take a export dump of login_table and want to import it into a table called table_login which has zero rows but having same table structure and it is present in another database. Please reply soon.Please reply soonWhy?
This is a forum of volunteers, so no one is under any obligation to you. Please stop to be demanding and consequently insulting.
Also what doubt do you have? It wouldn't work? This begs the question why you just didn't try? No one ever died from working.
Sybrand Bakker
Senior Oracle DBA -
Regarding import and export statement
hi experts,
how to import and export the internal table between programs...
Nice solutins with maximum points.....Example of a program exporting an internal table to ABAP memory.
Prog 1
parameters: pa_vbeln like vbak-vbeln.
data: itab type standard table of vbak.
* get data to fill the table
select * from vbak into table itab
where vbeln = pa_vbeln.
* now store the internal table to ABAP memory
export itab to Memory ID 'table''.
* here we call another program, prog 2
submit prog2 and return.
Prog 2 -> This imports the internal table exported by prog 1 and writes the content of the internal table to a list
data: jtab type standard table of vbak,
wa_vbak type vbak.
* importing the itab that was exported by prog1
import itab to jtab from memory id 'table'.
loop at jtab into wa_vbak.
write:/ wa_vbak-vbeln,
wa_vbak-erdat.
endloop.
* clear the specific memory id after required processing is complete
free memory id 'table'
Hope this solves your problem.
Cheers,
Sougata.
Subas,
Copy/paste your code, I'll have a look. First check if data is being selected before Export command.
Edited by: Sougata Chatterjee on Jan 11, 2008 12:31 PM
Also make sure you create prog2 as an executable program. Then, run prog1 with a valid Sales Order number. To understand it more clearly run it in debugging mode and step through. It should work fine in any system.
Edited by: Sougata Chatterjee on Jan 11, 2008 12:42 PM -
Data importing and exporting problem between BADI's
Hi Experts,
I am facing a problem in importing and exporting the data between badi's.
I am able to import and export the data between DOC CHANGE and DOC CHECK BADI's etc; but now i have a requirement to map a field from SRM to R/3.
Supplier order key field which is added to the basic data section of Shopping Cart should be mapped to the corresponding fields in R/3. I have added the field and when i am trying to map it to R/3 i am facing the probelm.
This Supplier order key field will be coming from ZBBP_CATALOG_TRANSFER badi and i am trying to map it in the Z_BBP_CREATE_PO_BACK Badi; i tried by using the below statement to export a single parameter to PO BACK badi from CATALOG TRANSFER Badi
EXPORT zsupp_ord_key FROM zsupp_ord_key TO MEMORY ID 'Z_SUPP_ORD_KEY'.
which is not working.
IMPORT zsupp_ord_key TO zsupp_ord_key FROM MEMORY ID 'Z_SUPP_ORD_KEY'. in PO BACK BADI.
Can any one please let me know why this is happening?
And i have strange problem in this ...
when a user copies a catalog which is already created then we can not map the field to R/3 PO
and again if he tries to create a cart by selecting "Old carts which are already created" we cant map field for the above two things to happen i think we need a custom coding .....
Thank you
Lokesh.Hi Lokesh,
BADI implementations have classes for which an instance is created at runtime and hence the import and export memory logic will not work.
Please try to create a function module for these BADI and call them in these BADI's. Then go ahead with the import and export logic. This could help.
I would rather advice, to figure out an option to avoid this memory manipulations.
Regards
Kathirvel -
Import and Export in 4.6b
Hi All,
I have a syntax regarding Import and Export statements which are not working in 4.6b. Below is the statement.
IMPORT ID = (Internal Table) FROM DATA BUFFER ( String Variable ).
EXPORT ID = (Internal Table) TO DATA BUFFER ( String Variable ).
What can we have alternate to above statements ?
Actually I need to transfer or export some internal table content to String and Import the same data from string.
I am looking perticularly about buffer only. If not that what can we have alternate to that ?
Thanks,
RamHi
You can try to use Field symbols also, for example
you need to code in the target program.
field-symbols <fs_itab> type standard table.
assign '(PROGRAMNAME)ITAB[]' TO <FS_ITAB>.
example, i did this in user exit
assign '(SAPMV50A)XLIPS[]' to <FS_ITAB>.
if <FS_ITAB> is assigned.
code will continue
make sure program name is in capital letters.
Regards
Madhan -
hi guys, im currently making a program that imports and exports data into a memory so that when the user logs out that would still remain in the memory. The data would be use for the slection screen but i can't seem to make it work. Could you please help me. Or if you have other ideas on how to store data that would also be ok. The thing is when Im running the program through se38 its working fine but if i run it through its transaction code the import does not work. Please help.
here is my code:
DATA: begin of i_memory,
memory_id(31),
end of i_memory.
initialization.
IF p_prem IS INITIAL.
CONCATENATE c_memory_id sy-uname into v_memory_id
SEPARATED BY c_underscore.
IMPORT i_memory FROM MEMORY ID v_memory_id.
IF sy-subrc = 0.
p_prem = i_memory-memory_id.
ELSE.
p_prem = '0.04'.
Endif.
ENDIF.
at selection-screen.
i_memory-memory_id = v_memory_obj.
CONCATENATE c_memory_id sy-uname into v_memory_id
SEPARATED BY c_underscore.
EXPORT i_memory to MEMORY ID v_memory_id.
IF sy-subrc = 0.
Endif.
Please help. Thanks in advance guys.Shekhar Kulkarni
I need help understanding your code.
Im trying to do same thing as you described in the post.
My main purpose is to IMPORT variant contents from cluster table VARI for all the selection screen variables dynamically.
I can IMPORT individual screen variables :: For ex :
st_key-report = 'ZNIDHS20'.
st_key-variant = 'TEST_VAR'.
IMPORT slsin_p TO TMP_VAR FROM DATABASE VARI(VA) ID ST_KEY.
This will get me the contents of slsin_p parameter in variant TEST_VAR of program ZNIDHS20.
But If I use same statement in a loop, im not able to get the data. : see below
LOOP AT i_selection_table..
IMPORT i_selection_table-name TO TMP_VAR FROM DATABASE VARI(VA) ID ST_KEY.
ENDLOOP.
I found your post interesting and started to test this way....As said, I have extracted selection screen variable table, and then tried to EXPORT the contents to Share Memory from database table VARI(VA), unfortunately program fails. Pls see code below....Pls see if you can help me out...
DATA: BEGIN OF st_key,
report LIKE rsvar-report,
variant LIKE rsvar-variant,
END OF st_key.
data : i_selection_table like rsparams occurs 0 WITH HEADER LINE,
v_rsvar like rsvar-report.
st_key-report = 'ZNIDHS20'.
st_key-variant = 'VJ_TEST'.
V_RSVAR = 'ZNIDHS20'.
data : begin of itab occurs 0,
COL1(40) type c,
COL2(40) TYPE C,
end of itab.
CALL FUNCTION 'RS_REFRESH_FROM_SELECTOPTIONS'
EXPORTING
CURR_REPORT = V_RSVAR
TABLES
SELECTION_TABLE = i_selection_table
EXCEPTIONS
NOT_FOUND = 1
NO_REPORT = 2
OTHERS = 3.
LOOP AT I_SELECTION_TABLE.
MOVE I_SELECTION_TABLE-SELNAME TO ITAB-COL1.
APPEND ITAB.
ENDLOOP.
EXPORT (ITAB) TO SHARED MEMORY VARI(VA) ID ST_KEY.
IMPORT ITAB = JTAB FROM SHARED MEMORY VARI(VA) ID ST_KEY.
Pls help..... -
Internal table with Import and Export
Hi All,
Hi all
Please let me know the use of <b>Internal table with Import and Export parameters and SET/GET parameters</b>, on what type of cases we can use these? Plese give me the syntax with some examples.
Please give me detailed analysis on the above.
Regards,
PrabhuHi Prabhakar,
There are three types of memories.
1. ABAP MEMORY
2. SAP MEMORY
3. EXTERNAL MEMORY.
1.we will use EXPORT/ IMPORT TO/ FROM MEMORY-ID when we want to transfer between ABAP memory
2. we will use GET PARAMETER ID/ SET PARAMETER ID to transfer between SAP MEMORY
3. we will use EXPORT/IMPORT TO/FROM SHARED BUFFER to transfer between external memory.
ABAP MEMORY : we can say that two reports in the same session will be in ABAP MEMORY
SAP MEMORY: TWO DIFFERENT SESSIONS WILL BE IN SAP MEMORY.
for ex: IF WE CALL TWO DIFFERENT TRANSACTIONS SE38, SE11
then they both are in SAP MEMORY.
EXTERNAL MEMORY: TWO different logons will be in EXTERNAL MEMORY.
<b>Syntax</b>
To fill the input fields of a called transaction with data from the calling program, you can use the SPA/GPA technique. SPA/GPA parameters are values that the system stores in the global, user-specific SAP memory. SAP memory allows you to pass values between programs. A user can access the values stored in the SAP memory during one terminal session for all parallel sessions. Each SPA/GPA parameter is identified by a 20-character code. You can maintain them in the Repository Browser in the ABAP Workbench. The values in SPA/GPA parameters are user-specific.
ABAP programs can access the parameters using the SET PARAMETER and GET PARAMETER statements.
To fill one, use:
SET PARAMETER ID <pid> FIELD <f>.
This statement saves the contents of field <f> under the ID <pid> in the SAP memory. The code <pid> can be up to 20 characters long. If there was already a value stored under <pid>, this statement overwrites it. If the ID <pid> does not exist, double-click <pid> in the ABAP Editor to create a new parameter object.
To read an SPA/GPA parameter, use:
GET PARAMETER ID <pid> FIELD <f>.
This statement fills the value stored under the ID <pid> into the variable <f>. If the system does not find a value for <pid> in the SAP memory, it sets SY-SUBRC to 4, otherwise to 0.
To fill the initial screen of a program using SPA/GPA parameters, you normally only need the SET PARAMETER statement.
The relevant fields must each be linked to an SPA/GPA parameter.
On a selection screen, you link fields to parameters using the MEMORY ID addition in the PARAMETERS or SELECT-OPTIONS statement. If you specify an SPA/GPA parameter ID when you declare a parameter or selection option, the corresponding input field is linked to that input field.
On a screen, you link fields to parameters in the Screen Painter. When you define the field attributes of an input field, you can enter the name of an SPA/GPA parameter in the Parameter ID field in the screen attributes. The SET parameter and GET parameter checkboxes allow you to specify whether the field should be filled from the corresponding SPA/GPA parameter in the PBO event, and whether the SPA/GPA parameter should be filled with the value from the screen in the PAI event.
When an input field is linked to an SPA/GPA parameter, it is initialized with the current value of the parameter each time the screen is displayed. This is the reason why fields on screens in the R/3 System often already contain values when you call them more than once.
When you call programs, you can use SPA/GPA parameters with no additional programming overhead if, for example, you need to fill obligatory fields on the initial screen of the called program. The system simply transfers the values from the parameters into the input fields of the called program.
However, you can control the contents of the parameters from your program by using the SET PARAMETER statement before the actual program call. This technique is particularly useful if you want to skip the initial screen of the called program and that screen contains obligatory fields.
Reading Data Objects from Memory
To read data objects from ABAP memory into an ABAP program, use the following statement:
Syntax
IMPORT <f1> [TO <g 1>] <f 2> [TO <g 2>] ... FROM MEMORY ID <key>.
This statement reads the data objects specified in the list from a cluster in memory. If you do not use the TO <g i > option, the data object <f i > in memory is assigned to the data object in the program with the same name. If you do use the option, the data object <f i > is read from memory into the field <g i >. The name <key> identifies the cluster in memory. It may be up to 32 characters long.
You do not have to read all of the objects stored under a particular name <key>. You can restrict the number of objects by specifying their names. If the memory does not contain any objects under the name <key>, SY-SUBRC is set to 4. If, on the other hand, there is a data cluster in memory with the name <key>, SY-SUBRC is always 0, regardless of whether it contained the data object <f i >. If the cluster does not contain the data object <f i >, the target field remains unchanged.
Saving Data Objects in Memory
To read data objects from an ABAP program into ABAP memory, use the following statement:
Syntax
EXPORT <f1> [FROM <g 1>] <f 2> [FROM <g 2>] ... TO MEMORY ID <key>.
This statement stores the data objects specified in the list as a cluster in memory. If you do not use the option FROM <f i >, the data object <f i > is saved under its own name. If you use the FROM <g i > option, the data objet <g i > is saved under the name <f i >. The name <key> identifies the cluster in memory. It may be up to 32 characters long.
Check this link.
http://www.sap-img.com/abap/difference-between-sap-and-abap-memory.htm
Thanks,
Susmitha.
Reward points for helpful answers. -
I am trying to use import and export statements in two different programs . The control from one program goes to another program with the function modules they have . I dont see the value while importing.
export i_field1 to memory id 'bus_ind'
import val1 to memory id 'bus_ind'
i gave only the memory id as common namePlease make sure that the variables used are the same name and defined exactly the same in both programs.
export i_field1 = i_field1 to memory id 'BUS_IND'.
import i_field1 = i_field1 to memory id 'BUS_IND'.
Regards,
Rich Heilman -
How to import and export the screen parameters
hi all
how to import and export the parameters of the screen
i need to export all the parameters and then import it
and also how to export and import a variable to the memory
thanks and regards
naval bhattHi,
Check this example for exporting and importing to memory..
DATA: V_VALUE(2) VALUE '2'.
EXPORT V_VALUE = V_VALUE TO MEMORY ID 'ZTEST'.
IMPORT V_VALUE = V_VALUE FROM MEMORY ID 'ZTEST'.
Thanks,
Naren -
Import and Export transport requests on Netweaver 2004s Sp11 Sneak Preview
Hi Experts,
I have configured the transportation system <STMS> in order to import and export transport requests on the NSP system. The configuration is working properly as files can be imported and exported out of the C:\sapmnt\trans directory. (configuration distributed by STMS -> Overview -> Systems -> Extras -> Distribute TMS Configuration, Folder SAPMNT shared).
The problem I'm facing with the import of some example transports is given by the hanging import queues. In phase 'Import ABAP Dictionary Objects' I have the following message for almost all objects -> '... was not imported in this step'.
I tried to solve this issue by running SE38->RDDNEWPP with DDIC user to schedule job RDDIMPDP for TP imports. I also made the config in TP_DOMAIN_NSP.PFL with SYSTEM_PF = C:\SAP\NSP\SYS\profile\DEFAULT.PFL.
The error is still in logfile SLOG0732.NSP
ERROR: The following call returned with exit code 7:
ERROR: sapevt.exe SAP_TRIGGER_RDDIMPDP -t name=NSP
and logfile dev_evt
ERROR ***: MsSndTypeOnce, rc = -20
ERROR ***: Event raise failed
With the exports there is a similar issue in the EXPORT phase, given the note
0 entries from WDY_APPLICATIONT exported.
Batch process is available (parameter rdisp/wp_no_btc = 1)
Profile has been activated by rz10->utilities->import profile->ofactive servers.
Any ideas what still can be wrong? Does the import export and DDIC activation really work with the sneak preview?
Thanks
ChristophHi Peter
First of all thanks for your advice.
I did No. 1. 2. 3. steps.
Step 4. reacts with the folowing error message.
Transport control program tp ended with error code 02008.
Errors: error in transportprofile (param missing, unknown).
My license expires in four days. I tried to extend it via http://www.sap.com/minisap
1. System-ID *
2. Hardware-Schlüssel (HWID) * ?
3.Systemnummer ?
What is to be entered in 1 and 2.
Where should I look for HWID and Sysnr ?
Thanks a lot again for your help
With regards
Fisseha -
Import and export CRM catalogue
Hi,
I am neewbie in CRM.
I would like to export CRM catalogue, and then import it into other computer.
For example, I am in TEST environment... navigate into "COMM_PCAT_ADM" and select "SALES_CATALOGUE".
I would like to EXPORT "SALES_CATALOGUE" to other TEST environment in a different computer.
1.- How could I do this?
2.- Do I have to export and import the catalogue or just tables / programs?
3.- Do I need any other information to export and import? For example Materials...
4.- How do I export the catalogue? Software?
5.- How do I import the catalogue? Software?
Thanks,
Regards.
Iker Espinosa.my import and export utility in oracle database 10g is not working. how to overcome this problem.why? Post the error with more information.
-Anantha -
Import and export MDM with the SAP Portal
Hi,
Would you have any clue on how to handle import and export from the SAP portal ?
I need your help because I haven't found any standard iView to perform these functions
The only information i got were some explanations on WebDynpro Java iViews using events to export from the Portal.
Thank you in advanceHi,
MDM iViews are only meant to perform MDM Data Manager operations but on limited basis. EP-MDM scenario has been designed for end users only which should not allow to perform complex data manager operations and they need not install MDM Clients.
Thats why importing and exporting functionalities are not possible in standard MDM iviews.
Regards,
Jitesh Talreja -
When we exit from the local Developer Studio, in the next attempt to start the Developer studio we are not able to import/export the DC, because the import and export file system options are not available in the popup window.
To achieve it we are reinstalling the JDK as well as NWDS.
What could be the reason and please send the suggestions to resolve this issue.Hi,
Close the project when exiting from the studio. So next time, you open studio, open the DC and check if you get the options.
Regards,
Harini S -
Import and Export of R prediction model
hi ,
How can i import and export a oracle R prediction model e.g from/to file ? Basically, We need it for the following requirements
1. We would like to ship a sample prediction model as part a product. So, The product will work with sample prediction model for some time after install till a newer model is created with data in customer env.
2. Before regenerating a prediction model, we would like to take a backup of the existing prediction model. And if it turns out that the prediction results are not as good with new model, we should be able to reinstate the older model.
3. Support a mode where oracle R prediction model can be loaded to an environment which is different from the the source environment where the model was actually generated.
Please advise
Regards,
ArifI tried the above method but i am facing an issue that although the prediction model is imported in to R using load command, it is not loaded in ORE environment. Due to this i am not able to use the imported predictionmodel for scoring
I tried the following
#Generate the prediction model
> PREDICTIONMODEL <- ore.odmKMeans(data= TEST_DATA_TABLE, formulat= COLUMN1 ~ . )
> class(PREDICTIONMODEL)
[1] "ore.odmKMeans" "ore.model"
> save( PREDICTIONMODEL, file="test.model")
After this i quit the R session (without saving my workspace) and then create a new R session and tried the following
# load a prediction model from a file
> load(file="test.model")
> ls()
[1} "PREDICTIONMODEL"
> ore.ls()
charcter(0)
You can see from above that ore.ls() is not printing anything after load(). However, ls() prints the loaded PREDICTIONMODEL. Now, if i try to do scoring against the loaded predictionmodel, I get an error
> x <- data.frame(COLUMN2="CC_PROCESSING", COLUMN3="CallWorkflow", COLUMN4="CallWorkflow", COLUMN1=NA)
> X <- ore.push(x)
>
> result<- ore.predict(PREDICTIONMODEL, X)
Error in .oci.GetQuery(conn, statement, data = data, prefetch = prefetch, :
ORA-40284: model does not exist
So, it seems that even though i imported the model from the file, ORE is still not aware of it . Any idea about this ? -
Import and export of a project.
Hi,
I want to know the steps of import and export of a project.
1.I am using DTR.
2.I selected a track, after that a SC.
3.There are a lot of DCs.
4.Now i am to select some DCs.
5.there are five DCs that makes an application.
Questions:
1.How i am to create the application in WD prespective??
2.After creation application in WD, how i am to deploy the application(with all DCs)??Hi,
Right click on the DCs which you want to get in the IDE and select Create Inactive Project.
If it prompts for the dependencies select them.
Once this is done u will be able to see the project in the WD perspective.
Now right click on the DC and select Development Component -> Build .
then Development Component -> Deploy.
If its there are any errors related with hard references deploy those DCs first and try.
Regards
Ayyapparaj.
Maybe you are looking for
-
How to go to the location of file that I received ...
How to go to the location of file that I received on skype? I was able to do it easily in old version. Now, I recieved the zip file. If I click on the file, it shows the Zip File View. I don't know where that file is downloaded. (of cuz, need to dip
-
When is the flash player 9 sdk to be released?
-
API for PO freeze/unfreeze, hold/release hold, open, open for invoice
I know there is PO_ACTIONS.CLOSE_PO API which allow us to close the PO. We need to Freeze, Unfreeze, HOLD, release hold, open, open for invoice and open for receiving standard purchase orders. Does anyone know the Oracle API which can do this jobs. T
-
Updating Safari 3.0.4 to 3.1.2
After downloading safari updating 3.1.2 impossible to load the package Safari311UpdLeo.pkg. I receive the following message : "Vous ne pouvez pas installer Safari sur ce volume. Cette mise à jour requiert Mac OS X 10.5.2 ou ultérieur.(you cannot inst
-
Is there a way i can find out what sites were looked at in private browsing
I am just wondering if there is a way i can find out what web pages sites or other searches were looked at while using the private browsing?