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: 

How to make a key field manadatory, in a Z-Table (SE11)

former_member195355
Participant
0 Kudos

Hi,

I've created a Z-table is se11 and one of the key fields is IWERK. Now the user does not want this field to be blank when they enter data into the table via SM30.

Does anyone know how to make this field so that a blank entry is not acceptable.

Many Thanks!

1 ACCEPTED SOLUTION

Former Member
0 Kudos

Hi Robert,

Edit the Ztable in se11, uncheck the 'Initial' checkbox for this key field, and then generate table maintenance windows thru SM30.

<b>Robert, once activated, you cannot uncheck 'Initial' checkbox. Recreate the ztable again and remember to uncheck 'Initial' checkbox for the key field.</b>

Regards,

Raj

Message was edited by: Rajasekhar Dinavahi

5 REPLIES 5

Former Member
0 Kudos

Hi Robert,

Edit the Ztable in se11, uncheck the 'Initial' checkbox for this key field, and then generate table maintenance windows thru SM30.

<b>Robert, once activated, you cannot uncheck 'Initial' checkbox. Recreate the ztable again and remember to uncheck 'Initial' checkbox for the key field.</b>

Regards,

Raj

Message was edited by: Rajasekhar Dinavahi

christian_wohlfahrt
Active Contributor
0 Kudos

Hi Robert!

One way would be to adjust SM30 to a mandatory field (in SE11 of course), but this field sounds like you can assign T001W as a check table. In the foreign key definition, you can give a error message, which is called in case of wrong entries in screens -> there is no empty entry in T001W, you can only maintain valid values and got a value list.

Regards,

Christian

P.S.: No, you need to change SE11->Table maintenance generator->Enviroment->Modification->Maintenance Screens->Element list->Tab Special attr. column Input. Set 'required'. Otherwise empty is still allowed

Message was edited by: Christian Wohlfahrt

0 Kudos

Hi!

The initial-flag (beneath key-flag) is changing behavior when creation empty values: here the difference is between a NULL-value in DB or the SAP-initial value (which might be space or 0).

As far as I know, there is no difference on screens depending on this initial-flag.

But maybe I'm wrong, Raj, no offense!

Regards,

Christian

0 Kudos

Hi Christian,

Unfortuanately I have already set up an entry for T))1W to be a check table but an empty value can still be entered

However, Your other suggestions sounds great but I tried your menu path:

SE11->Table maintenance generator->Enviroment->Modification->Maintenance Screens->Element list->Tab Special attr.

But unfortuantely I couldn't see a column Input checkbox? Are you sure this path is correct. We run 4.6B...

Many Thanks!

0 Kudos

Hi Robert!

I'm working on ERP 5.0, so there <i>might</i> be a different display. But when you reach element list, just mark your field an press button Attributes. Then the input options is in subscreen Program (second field).

I hope this still looks similiar.

Regards,

Christian