05-30-2008 1:48 PM
Hi Everyone,
Could you please let me know the Export and Import commands with a example,How can you pass more than one group of data by using IMPORT commands?
Thanks in Advance,Hope, early reply from your end.
Regards,
Ansar
05-30-2008 1:57 PM
Hi Pal,
For your info IMPORT & EXPORT commands are used for ABAP Memory.
That means that it limited to your session.
U cannot import data till u export data
U can acess data between programs by using these commands.
Eg:
***********************************************
p_bukrs = '21'
EXPORT v_bukrs FROM p_bukrs TO MEMORY ID 'COMP'.
IMPORT v_bukrs TO l_v_cocde FROM MEMORY ID 'COMP'.
write: l_v_cocde
*****************************************************
When u import l_v_cocde will have value '21'
Here u dont need to declare v_bukrs since it is a variable which temporailry holds the value. It is handled by the sap.
Hope this helps..
Thanx,
Navin
05-30-2008 2:04 PM
Hi Basha,
You can use this function to export and import database objects. BR*Tools uses Oracle export and import functionality to:
---> Export database objects
You can export tables with their data, table and index definitions, and with other database objects such as constraints, grants, views, synonyms and sequences.
---> Import database objects
You can import objects that have earlier been exported.
---> Export database objects to null device
You can use this to validate database objects.
Export and import enables you to back up database objects in addition to other database backups. If you only want to back up particular tables, export is a good method. For example, you can add to the data backup you perform before a reorganization by exporting the objects that are to be reorganized.
please check this link
http://help.sap.com/saphelp_nw70/helpdata/en/7c/209667b05b844399f6402a0213ef95/content.htm
http://www.abapcode.sapbrainsonline.com/2008/03/import-abap-keyword.html
Best regards,
raam
05-30-2008 2:24 PM
Check this simple example
REPORT ZTEST_PARAMTER_ID.
data: vbeln type vbeln.
parameters: p_test type char10.
start-of-selection.
Break-point.
import vbeln to vbeln from memory id 'abc'.
if vbeln is initial.
vbeln = '123435'.
export vbeln from vbeln to memory id 'abc'.
endif.
write vbeln.
05-30-2008 2:25 PM
Hi Basha,
IMPORT and EXPORT are using for suppose you want to process the data based on one document number which exists in another program then first export that document number from that report and keep in some memory area called ABAP meomory and import that document number from that meomry in current program.
Regards,
KUmar.