2006 Oct 27 6:32 AM
Hi,
I have created a table ztest. How to force user to enter the values for certain fields in the table which are not keys, similar to not null in RDBMS. selecting the initial values filed in SE11 populates with some default value, but it doesnt force the user to enter the value.
Regards,
Raghu
Hi,
I have created a table ztest. How to force user to enter the values for certain fields in the table which are not keys, similar to not null in RDBMS. selecting the initial values filed in SE11 populates with some default value, but it doesnt force the user to enter the value.
Regards,
Raghu
2006 Oct 27 6:34 AM
You do it in your coding , where you try to insert into the table.
check if not initial, proceed with the insert statement or modify statement
regards,
Sandeep Josyula
*Reward for helpful answers
2006 Oct 27 5:09 PM
hi,
In the programs which updates this particular table, logic needs to be coded to check if the particular fields are not initial and proceed with updating Database table.
2006 Oct 30 4:07 AM
Hi Raghu,
Create your own transaction for updating the database table similar to se16 and validate in PBO for Null entries
Regards:-
Shankar
2006 Oct 30 4:16 AM
Hi Raghu,
I database level, the only possibility for this is to use Foreign keys(Maintain proper entries in Check table and create a foreign key to that table). Hope your requirements is fullfilled.
Cheers..
Santosh
P.S. Mark usefull answers
2006 Nov 01 8:46 AM
Hi,
Just check out transaction code SE54 for events.
Go in SE54.
Give your table name.
Go in Environment --> Events.
Here add the Event '01' i.e. Before saving the data.
Give the name for event eg 'BEFORE_SAVE'.
Click on Editor to create an include program.
In the include program write
form before_save.
data: f_index like sy-tabix. "Index to note the lines
loop at total.
if <action> = 'N' or <action> = 'U'.
read table extract with key <vim_xtotal_key>.
if sy-subrc eq 0.
f_index = sy-tabix.
else.
clear f_index.
endif.
"(make desired changes to the line TOTAL)
"End of Modification.
**********
modify total.
check f_index gt 0.
extract = total.
modify extract index f_index.
endif.
endloop.
sy-subrc = 0.
endform.
Note here in field symbol 'Total' your workarea will be their. You can make necessary checks here.
Or else you can go for making a custom transaction for your requirement.
Regards,
Nitin
*Mark all helpful answers