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

Table control question

Former Member
0 Likes
500

I am planning to write a program related to table control for updating/inserting/deleting a record into internal table or database table.

Is it must that the internal table or database should have a field called 'mark' with C type and length 1? For example, I see in the database table Mara, there is no field called 'mark' at all. Does that mean we can't insert/update/delete a record from Mara? Definitely not.

Can you please make it clear on this concept? Thanks in advance.

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
472

hi Nuren,

the mark that you are talking is the table control field not database field and you cannot find the same in the database so you need not bother about mark field to be present in the database

5 REPLIES 5
Read only

RichHeilman
Developer Advocate
Developer Advocate
0 Likes
472

No, this field doesn't have to exist in the DB table, just in your Internal table. This MARK field is just a way for the program to know what lines of the table contol have been selected. That's it.

data: begin of iztab occurs 0.
data: mark(1) type c.
      include structure ztab.
data: end of iztab.

Regards,

Rich Heilman

Read only

Former Member
0 Likes
473

hi Nuren,

the mark that you are talking is the table control field not database field and you cannot find the same in the database so you need not bother about mark field to be present in the database

Read only

Former Member
0 Likes
472

hi nuren,

in the screen painter if you are specifying w/selcolumn for the table control, then u need to declare a mark TYPE c in the internal table, then u can write like

in pai.

IF v_check(is the name of w/selcolumn in the screen) = 'X'.

itab-chk = 'X'.

MODIFY itab index tc1-current_line.

ELSE.

CLEAR itab-chk .

ENDIF.

Read only

Former Member
0 Likes
472

how can i add table control columns dynamically?

hari

Read only

Former Member
0 Likes
472

hi krishen,

no it absolutely not neccessary.

Thank you.