Sitemap

Amicuk Programming Answers

Confused with the internal table

-0001-11-30   Views:0

Advertisement

Hello, I am getting confused again by the usage of work space for an internal table. Say for example I have a internal table itab that is defined as: DATA:ITAB TYPE STANDARD TABLE OF Txxx. Then I define a work space for the internal table. DATA:WS_IT

Hello,
I am getting confused again by the usage of work space for an internal table.
Say for example I have a internal table itab that is defined as:
DATA:ITAB TYPE STANDARD TABLE OF Txxx.
Then I define a work space for the internal table.
DATA:WS_ITAB LIKE ITAB.
Now say for example, I would like to fill in some data to this internal table, can I do:
WS_ITAB-FIELD1 = 3.
APPEND WS_ITAB INTO ITAB INDEX 1.
where FIELD1 is a valid field in Txxx?
If not, how should I accomplish my goal? Thanks a lot!

The replay answer
Advertisement
Yes, you have the right idea.  When working with work areas it is a good idea to define them like line of itab. This way, anytime itab changes, the wa will also be updated.
DATA: ITAB TYPE STANDARD TABLE OF Txxx.
<b>data: wa like line of itab</b>.
You can add a line to your internal table by filling the work area and appending to the internal table.
wa-fld1 = 'A'.
wa-fld2 = 'B'.
wa-fld3 = 'C'.
append wa to itab.
You can insert into a specific index by using INSERT.
Insert wa into itab index 1.
Regards,
Rich heilman

Go to See the other 8 answers

Confused with the internal table

Category:DefaultRelease time:-0001-11-30Views:130

Hello, I am getting confused again by the usage of work space for an internal table. Say for example I have a internal table itab that is defined as: DATA:ITAB TYPE STANDARD TABLE OF Txxx. Then I define a work space for the internal table. DATA:WS_IT[More]

Internal table occurs 0 --------- why obsolate?

Category:DefaultRelease time:2015-10-11Views:130

Hi, Can anybody tell why the declaration of internal table occurs 0 and internal table with header line is obsolate now? Explain the adavantages of newer one. is there any performance related issue? Thanks in advance Debjani LahiriHi, Like all other[More]

Creation of Sorted and Standard and Hashed Internal Tables ..

Category:DefaultRelease time:-0001-11-30Views:130

Hi .. Pls  specify me.. how to create .. sorted ,Standard and Hashed Internal Tables... pls give me  the full code  regarding ...this .. ThnksStandard tables This is the most appropriate type if you are going to address the individual table entries u[More]

Internal Table and Structures

Category:DefaultRelease time:-0001-11-30Views:130

Hi, I am a beginer. I know how to create a structure and how to create an internal table using ABAP/4. My problem is, i don't understand where to use internal table and structure, also i find myself very confused about the explicit work areas. Plese[More]

Difference betwen the internal tables

Category:DefaultRelease time:-0001-11-30Views:130

Hai friends,            Pls give me the types  of internal tables and their   differences .and its usage by example.   regrds, Prashanth.Internal tables Definition Data structure that exists only at program runtime. An internal table is one of two st[More]

Select on MARA resulting into # values in internal table for one field

Category:DefaultRelease time:2015-10-11Views:130

Hi Team, I have written a SELECT statement on MARA table as below. TRY.         SELECT matnr zzwftag FROM mara CLIENT SPECIFIED           INTO CORRESPONDING FIELDS OF TABLE gt_mara WHERE           mandt = sy-mandt AND           zzwftag NE space      [More]

How to create Dynamic Internal table in ALV?

Category:DefaultRelease time:2015-10-11Views:130

Hi all, I have to create a ALV report based on dynamic internal table. The requirement is that when I enter the months in my selection screen I should get the data relevant to those many months only. For eg if in selection I have given January to Mar[More]

To convert XML to ABAP internal table can we do it with DOM or we need XSLT

Category:DefaultRelease time:2015-10-11Views:130

I have a requirement where I need to collect the data from XML file into an internal table. I need to collect this data into an internal table as I should make use of this data and do Goods Receipt in SAP. My XML file is very very complex and the chi[More]

How to display Internal Table in ALV?

Category:DefaultRelease time:2015-10-11Views:130

Hi all, can anyone teach me the simple way to insert my internal table records to ALV by providing me the sample codes from the start of declaration to the end? Below is how i define my internal table: DATA: DOM_NAME(40) TYPE C,        P_TABLE(40) TY[More]

Data present in  internal table, now how to open it in PDF format

Category:DefaultRelease time:2015-10-11Views:130

Dear Friends, my Scenario is.. I have uploaded a pdf file in my database table through  GUI_UPLOAD. It is uploaded. Now when user click on some button then that file should be displayed again in pdf format directly. (No download to user PC using GUI_[More]

ABAP OO - Passing Internal Tables from Method to Method

Category:DefaultRelease time:2015-10-11Views:130

I'm new to writing methods. I have a need to build an internal table in METHOD1 and pass the internal table to METHOD2. I'm confused how to declare the table in 'Parameter' section of the METHOD2. I have specified the following: Parameter = WTAB1 Typ[More]

Hot
I am still having problems with my Save For Web interface. Attached is a screen where you can see that with just the Optimized view showing (in this case 72%), the picture looks as expected. But if I go to 2-up or 4-up views, the 2nd image (which was [More]
Hi I have an java class which works as a workflow client. When i run the class i get the error as following: ORABPEL-10509 User is not found. User "jcooper" is not found in realm "jazn.com" The java code i have is like below: IWorkflow [More]
I am developing an HTML application using LabVIEW Web Services in version 8.6. I configured a VI to output data as XML.  I am using the jQuery framework for javacript at this time. I noticed that when I try to get the data from this VI as XML jQuery [More]
Dear Experts In ESS portal employee photo is missing. Config ESS in R3 system 1.Table T77S0 ADMIN PHOTO HRICOLFOTO. 2.Maitain ESS Setting, Display Employee photograph is flagged. under change who who data, both option is flagged. Please guide me ,i'm [More]
Hi experts, Can any one give me guidelines on SRM Analytics and i need documentation on same. it's very urgent because one of the clients wants working on SRM Analytics i will assign points Thanks in advance Regards venu.Dear Venu, SRM Analytics cont [More]
I am using Oracle SQL*Plus client. declare tablename_var varchar(10); LOOK HERE date_var date; begin select sysdate into date_var from &tablename_var; LOOK HERE dbms_output.put_line('The system date is '||date_var); end; The above code prompts the us [More]
Hi everyone. I am not certain if I am in the correct section. I have a website designed in Flash. The site has a contact section with 3 fields (name, e-mail and message). Having completed these fields one would click "submit" to send the entered [More]
Hello all, I did several searches on this forum but didn't find what I needed. My problem: I recently upgraded to Tiger, and have had iLife '06 installed since Jaguar. Last night I went to start a new Project in iMovie and noticed none of the control [More]
Hi anybody,   Please tell me how to find the screen exit in MIGO Sceen. Thks Kali.GO TO TRANSACTIO CODE MIGO GO->SYSTEM->STATUS COPY THE PROGRAM NAME OPEN SE38 EDITOR GIVE THE PROGRAM NAME IN THE GLOABL SEARCH SEARCH THE STRING SELECT RADIO BUTTON M [More]
When I press File Open in my PSE 11 and look for Camera Raw files, they all show PSE 11 icon which makes it hard to find where is the image I am looking for? How do you make these CR2 ehumbnails to show the actual image? Thanks  Simply select a folde [More]