Skip to Content
author's profile photo Former Member
Former Member

1:C Foreign Key relationship (Cardinality ratio)

Hello All,

I have a requirement that for one record in check table, there should be at max. one record in foreign key table.

For this, I have given the cardinality ratio of my foreign key field to be 1:C.

Despite this, I am able to enter more than one records in my foreign key table against a record in check table.

Please suggest me where I am going wrong.

Thanks,

Saurabh Buksh

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

3 Answers

  • Best Answer
    author's profile photo Former Member
    Former Member
    Posted on Nov 30, 2007 at 06:05 PM

    Hi Saurabh,

    If you are trying enter records with a insert or update instruction the integrity won't be checked.

    What I learned from the book "Sams Teach Yourself ABAP/4 in 21 Days" is that there isn't integrity references in the database. The foreign keys integrity are checked by the user interface only.

    Regards,

    Charles

    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Nov 30, 2007 at 05:14 PM

    Try with cardinality <b>1:1</b> instead of the 1:C

    This is what I got from the Online Help..

    <i>The right side of the cardinality has the following significance:

    m = 1

    For each record of the check table there is exactly one dependent record.

    m = C

    For each record of the check table there is at most one dependent record.</i>

    Regards,

    Naimesh Patel

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Dec 02, 2007 at 06:19 AM

    HI

    Cardinality of a relationship

    The cardinality (n : m) describes the foreign key relationship with regard to the number of possible dependent records involved (records of the foreign key table) or referred records (records of the check table).

    The right side of the cardinality has the following significance:

    m = 1

    For each record of the check table there is exactly one dependent record.

    m = C

    For each record of the check table there is at most one dependent record.

    m = N

    For each record of the check table there is at least one dependent record.

    m = CN

    For each record of the check table there are any number of dependent records.

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.