Skip to Content
0

Maintanence View - text table without foreign key relationship

Oct 05, 2017 at 09:23 AM

72

avatar image
Former Member

Hi,

I have two tables each with two text tables - let's say "A" with "AT" and "B" with "BT".

Now I have a third table "C" which use a key field from A and one key field from B, like:

| MANDT | A-KEY | B-KEY | ... | ... |

I would like to display the texts for A-KEY from table AT. Same thing for B-KEY. How can i do this? Table C has no relationsships to table A/AT or B/BT . Thanks!

10 |10000 characters needed characters left characters exceeded

It's a big issue that table C has no foreign keys to tables A and B. Why can't you create them?

0
* Please Login or Register to Answer, Follow or Comment.

5 Answers

avatar image
Former Member Oct 05, 2017 at 10:25 AM
1

Hi,

If I understand your requirement correctly, you need to create a database view in SE11 with tables C, AT, and BT. The relationship should look something like this:


database-view.jpg (59.1 kB)
Show 1 Share
10 |10000 characters needed characters left characters exceeded
Former Member

Thank your. Please read my answer below :)

0
Bhagya Nayanala Oct 05, 2017 at 09:52 AM
-1

Hi

you can create a search help and make use of it.

Regards

Bhagya

Share
10 |10000 characters needed characters left characters exceeded
avatar image
Former Member Oct 05, 2017 at 10:51 AM
-1

Your answers are correct but I mean something different.

I want to use the view to add new entries.. If someone select an entry from A-Key via F4, I want to show the text in the next view field. The user should read the text without using F4 again.

Share
10 |10000 characters needed characters left characters exceeded
avatar image
Former Member Oct 06, 2017 at 01:56 AM
0

Hi,

You need to create a Table Maintenance Generator for table C. Note that table C should include the field that will handle the text value. Then, inside the FILL_HIDDEN event, create a subroutine that will select the text from another table, say table A.

I can't answer your question in detail here for it will be too long and I know there are many great resources around about Table Maintenance Generator, but at least, you now have an idea on how to go about what you are trying to achieve.

This will be a good place to start: Table Maintenance Generator and its Events

Share
10 |10000 characters needed characters left characters exceeded
Raymond Giuseppi
Oct 06, 2017 at 05:32 AM
0

Usually we use foreign relations for this, in a standard way you should have C -(check)-> A -(text)-> AT and C --> B --> BT so you could create a maintenance view in SE11 with the 3 tables and use it in the maintenance dialog.

Why didn't you create the foreign relation with the main tables, the 'Table C has no relationships to table A/AT or B/BT' would be considered an error on multiple if not most sites...

Else go for maintenance event handling and/or modification of dynpros (beware can be removed later inadvertently during regeneration if table changed)

Share
10 |10000 characters needed characters left characters exceeded