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

Foreign Keys

Former Member
0 Likes
1,264

Hi all,

A standard message is output if the value check by the foreign key on the screen field results in an invalid input. You can replace this standard message with any message. To do this, you must enter the message class of the message in the field AArea and the message number in the field MsgNo.

I created a messgae class in se91 and I have supplied the values 000 and ZMV to the specified fields. But I did not get the expected output. Can anyone please help me out with this.

Regards,

Varun.

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
1,236

Is the message class declared in the program and message class is activated

11 REPLIES 11
Read only

Former Member
0 Likes
1,236

Varun,

This is a bit difficult question to answer with out looking at the code.

Had you modified the code in PAI event?? We need to debug in order to figure out why you message statement is not getting executed. Paste your code if possible.

Thanks,

Read only

0 Likes
1,236

Hi Naren,

I did not write any code for this. I said I am creating a ztable. IN the fields I placed my cursor and I clicked the key icon next to search help.In the pop up screen There I have specified the check table and entered the values for Msgno and AArea as 000 and zvm.

This is the output I got.

E:ZVM:058 TR ZVT005

Read only

0 Likes
1,236

Hi all,

If I am not very clear go through the link :

http://help.sap.com/saphelp_46c/helpdata/en/6f/2000f79ffe11d3969500a0c929b3c3/frameset.htm

Under the other options read <b>Assign message</b> and please explain me how to achieve that.

Regards,

Varun.

Read only

Former Member
0 Likes
1,236

What output did you get (error message)?

Rob

Read only

0 Likes
1,236

Did you activate?

Rob

Read only

Former Member
0 Likes
1,237

Is the message class declared in the program and message class is activated

Read only

0 Likes
1,236

Varun,

Message number

Message number of the error message to be output.

Use

If an attempt is made to enter a value in a foreign key field of the dependent table which is not in the check table, a standard message is output. This standard message can be replaced by any message from table T100.

Procedure

To replace the standard message, you must enter the message class of the message to be output in field 'AGeb' and its message number in field 'MsgNr'.

Thanks,

Read only

0 Likes
1,236

Hi Naren,

I can see that you understood my problem. What you said I know already, but can you please explain me how do we do that.

Regards,

Varun.

Read only

0 Likes
1,236

Donot use the message number 000..instaed try giving the same message in a new number say 001...it will work...

Strange .!

Thanks,

Renjith

Read only

0 Likes
1,236

Hi,

The problem is solved. But what is the reason ? Why 000 did not work and why 001 worked ??

Regards,

Varun.

Read only

0 Likes
1,236

i think ..somewhere in sap code they might be checking "is initial" for the message number...and 000 is initial....

thanks,

Renjith