Results 1 to 5 of 5

Thread: failed to enable constraints one or more rows contain values violating non-null, uniq

  1. #1

    Thread Starter
    Addicted Member
    Join Date
    Jan 2003
    Posts
    175

    failed to enable constraints one or more rows contain values violating non-null, uniq

    dear sirs
    i have the folowing error
    "failed to enable constraints one or more rows contain values violating non-null, unique or foreign key"
    when i try to execute the attached code
    Me.adapConnWay.Fill(DsCompanies1.T_ConnectionDetails)
    in line 2964
    im also added the db and the code itself
    Attached Files Attached Files

  2. #2

    Thread Starter
    Addicted Member
    Join Date
    Jan 2003
    Posts
    175

    and attached the db

    the file was too large
    so i attached them seperately
    Attached Files Attached Files

  3. #3
    Frenzied Member
    Join Date
    Oct 2002
    Location
    Gammapolis
    Posts
    1,474
    If you try to preview the dataset data in the designer you will see what causes the problem. There are values in conndetails_entity_Code filed in T_ConnectionDetails table that does not exist in the parent table conntype_Code field. I guess you have made a mistake in editing the relations. Didnt you want to relate conndetails_conntype_Code to conntype_Code?

    By the way, is that Hebrew?
    Last edited by Lunatic3; Aug 24th, 2003 at 09:56 AM.
    'Heading for the automatic overload'
    Marillion, Brave, The Great Escape, 1994

    'How will WE stand the FIRE TOMORROW?'
    Eloy, Silent Cries and Mighty Echoes, The Vision - Burning, 1979

  4. #4
    Frenzied Member
    Join Date
    Oct 2002
    Location
    Gammapolis
    Posts
    1,474
    I think there is something wrong in your project regarding the datasets. Is dsCompanies1 an instance of dsCompanies or another dataset? Seems they are mixed up. Try deleting the datasets and add them again.
    'Heading for the automatic overload'
    Marillion, Brave, The Great Escape, 1994

    'How will WE stand the FIRE TOMORROW?'
    Eloy, Silent Cries and Mighty Echoes, The Vision - Burning, 1979

  5. #5

    Thread Starter
    Addicted Member
    Join Date
    Jan 2003
    Posts
    175

    replacing all ds companies

    Ok - so i have tried the to delete all the dscompanies1 and dscompanies - and created just dscompanies dataset. but still the X butten refuses to close the form - i attach the fixed code
    Attached Files Attached Files

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width