Application Development and Automation 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: 
Read only

regarding system variables

Former Member
0 Likes
941

what is the use of system variable sy-tabix.

it give no of rows in table r anyother value.

thanks in advance.

1 ACCEPTED SOLUTION
Read only

gopi_narendra
Active Contributor
0 Likes
902

Sy-tabix is used to find the current line in the internal table; it’s a current line index.

Where as if you need the number of rows of table you can use the describe statement

data N type I.

describe table itab lines N.

N - gives thenumber of rows of an internal table.

Regards

Gopi

7 REPLIES 7
Read only

Former Member
0 Likes
902

loop at it.

write: / sy-tabix.

endloop.

just check this.

S@meer

Read only

Former Member
0 Likes
902

when u r looping an table then sy-tabix gives the row number of the current iteration.

Read only

gopi_narendra
Active Contributor
0 Likes
903

Sy-tabix is used to find the current line in the internal table; it’s a current line index.

Where as if you need the number of rows of table you can use the describe statement

data N type I.

describe table itab lines N.

N - gives thenumber of rows of an internal table.

Regards

Gopi

Read only

Former Member
0 Likes
902

Hi,

it a table index in the internal table.

Sy-tabix is used in case of internal table.When u want to enter or retrive data from internal table at that time it is updated.

Reward points if is useful.

Read only

Former Member
0 Likes
902

Hi

chk this link

sy-tabix is mainly used in a loop statement.

loop at itab.

hese sy-tabix contains the number of current record that is processing in a loop.

endloop.

and used in update stmt. here sy-tabix contains the number of records that r modified

reward points to all helpful answers

kiran.M

Read only

kiran_k8
Active Contributor
0 Likes
902

Srini,

Some additional info:-SYST is the table which has all the system variables in SAP.

K.Kiran.

Read only

Former Member
0 Likes
902

hi moorthy

try this,then you wil come to know wat is tabix........

REPORT ZTABIX.

tables : mara.

types : begin of ty_final,

matnr type matnr,

end of ty_final.

types : tt_final type standard table of ty_final.

data : wa_final type ty_final,

itab_final type tt_final.

select matnr from mara into table itab_final.

if sy-subrc = 0.

loop at itab_final into wa_final.

write: / sy-tabix,

wa_final-matnr.

endloop.

endif.

reward if useful......!!!!!!!

cheers

asha