Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

hai abap gurus...

Former Member
0 Kudos
88

How to add new fields to a standard sap table ?

what is the difference bet'n table and a structure?

how do u define an internal table?

how many type of internal tables are there?

what is the difference between hashed & sorted internal

tables?

what is the difference between standard and sorted

internal tables? (in performance wise)

Difference between internal table and a dictionary table?

1 ACCEPTED SOLUTION

Former Member
0 Kudos
61

HI,

if sap has provided any customer structure structures only we can add extra fields

ex:ekko table.

in table we can store some data.in structure it is not possible.

<b>internal table:</b>

An internal table is a temporary table stored in RAM on the application server. It is created and filled by a program during execution and is discarded when the program ends. Like a database table, an internal table consists of one or more rows with an identical structure, but unlike a database table, it cannot hold data after the program ends. Use it as temporary storage for manipulating data or as a temporary private buffer.

<b>defining internal table:</b>

data: begin of it1 occurs 10, "has a header line

f1,

f2,

f3,

end of it1.

data it2 like ztxlfa1 occurs 100. "doesn't have a header line

data it3 like ztxlfa1 occurs 100 with header line. "it does now

<b>types of itabs and their differences:</b>

http://help.sap.com/saphelp_nw04/helpdata/en/fc/eb35de358411d1829f0000e829fbfe/content.htm

rgds,

bharat.

Message was edited by:

Bharat Kalagara

4 REPLIES 4

Former Member
0 Kudos
62

HI,

if sap has provided any customer structure structures only we can add extra fields

ex:ekko table.

in table we can store some data.in structure it is not possible.

<b>internal table:</b>

An internal table is a temporary table stored in RAM on the application server. It is created and filled by a program during execution and is discarded when the program ends. Like a database table, an internal table consists of one or more rows with an identical structure, but unlike a database table, it cannot hold data after the program ends. Use it as temporary storage for manipulating data or as a temporary private buffer.

<b>defining internal table:</b>

data: begin of it1 occurs 10, "has a header line

f1,

f2,

f3,

end of it1.

data it2 like ztxlfa1 occurs 100. "doesn't have a header line

data it3 like ztxlfa1 occurs 100 with header line. "it does now

<b>types of itabs and their differences:</b>

http://help.sap.com/saphelp_nw04/helpdata/en/fc/eb35de358411d1829f0000e829fbfe/content.htm

rgds,

bharat.

Message was edited by:

Bharat Kalagara

Former Member
0 Kudos
61

<b>How to add new fields to a standard sap table ?</b>

by include or append structure. Open a table in Se11. Go to edit, you will find the include. Search the toolbar, you will find the append structure option.

<b>what is the difference bet'n table and a structure?</b>

Table hold multiple rows, structure hold a single row.

In dictionary, table contain data, structure do not contain any data but only field defenations.

<b>how do u define an internal table?</b>

there are may ways. One i follow is:

types: begin of t_mara,

matnr type matnr,

end of t_mara.

data: it_mara type table of t_mara,

wa_mara like line of it_mara.

<b>how many type of internal tables are there?</b>

1. standard, shorted, hashed

2. withe header line and without header line

<b>what is the difference between hashed & sorted internal

tables?</b>

in sorted table the rows are in sorted order. We use a binary search to search anyy rows. <b>The responce time depends upon the logarithem of no of rows</b>.

in hashed table, hashed algorithem is used to store the rows. the searchin is done through a hash function. <b>The searching time is constant and do not depend upon the no of rows</b>.

So for lerger table, the searching will be efficient in case of hashed table.

<b>Difference between internal table and a dictionary table?</b>

internal table only exits when the runtime of the program. It is defined in the program. After the execution, it releases the memory

database tables exits in the database. so do not depend upon the program.

we generally, select the data from the database tables in the program. Stor in the internal table and then do nome algorithem and display the output on the screen.

Former Member
61

table: which has data in it n memory allocated at databse level.

structure: no memeory allocated to it.appers only at application serevr level.

internal table: it is defined using keyword occurs

ex: itab like mara occurs 0 with header line.

hashed table: uses hash algorithms

sorted table: uses sort algorithm n useful when data wants to be ascending r decending order.

internal table: created at presentation system level. its a dinamic table

database table: created n resided at database level. its a static table.

if helpfulreward some points.

with regards,

suresh babu aluri.

former_member582701
Contributor
0 Kudos
61

1- with struct append, If u go to Se11 transaction, together Tecnical settings u can see it.

2- Struct defines the format of a data. In other words, you can't append into an struct.

DATA: BEGIN OF i_itab OCCURS,

a type i,

v(8) type c,

END OF i_itab.

or

DATA: i_itab LIKE <name of a table> OCCURS 0 WITH HEADER LINE.

3- Sorted table insert new entries in his corresponding position.

4- Dictionary table? I dont know what is it.

Regards and reward all helpfull answers