Results 1 to 6 of 6
  1. #1
    zozzz is offline Advanced Beginner
    Windows 7 32bit Access 2010 32bit
    Join Date
    Oct 2013
    Posts
    49

    Stop Writing duplicate

    hello to all friends



    I have 5 fields in the subform called (name1 , name2 , name3 , name4 , NFather )
    but I Want when complete the 4 names and if NFather similar show me Error message

    thanks

  2. #2
    June7's Avatar
    June7 is online now VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    52,816
    If NFather similar to what - a name already in database? String pattern matching is not simple nor is it conclusive. Review http://allenbrowne.com/vba-Soundex.html
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  3. #3
    zozzz is offline Advanced Beginner
    Windows 7 32bit Access 2010 32bit
    Join Date
    Oct 2013
    Posts
    49
    hello June7

    Click image for larger version. 

Name:	not.jpg 
Views:	17 
Size:	72.7 KB 
ID:	29910

  4. #4
    June7's Avatar
    June7 is online now VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    52,816
    You can easily determine if the exact same spelling exists. But you said 'similar' in your question. But why can't the same spelling be in another record? Many people have the same name.

    If you want to prevent a duplication of a combination of the 5 fields, then set them as a composite index. This will force the entire record to be unique. If any one of the fields has a different value then the record is unique and not a duplicate. Review http://www.geeksengine.com/article/c...ex-access.html
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  5. #5
    zozzz is offline Advanced Beginner
    Windows 7 32bit Access 2010 32bit
    Join Date
    Oct 2013
    Posts
    49
    Yes, you are right
    But I wanted to be just said one example ....
    I'm very grateful if you can complete the sample


    no duplicate.zip

  6. #6
    June7's Avatar
    June7 is online now VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    52,816
    Suggest you delete the duplicates then set the composite index.
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Stop Duplicate entries in a sub form
    By Headford in forum Forms
    Replies: 1
    Last Post: 03-04-2014, 09:52 AM
  2. Replies: 6
    Last Post: 03-01-2014, 07:07 AM
  3. Stop Duplicate name entry
    By bharatdubole in forum Access
    Replies: 1
    Last Post: 12-03-2012, 06:11 AM
  4. Replies: 1
    Last Post: 12-09-2011, 07:34 AM
  5. Replies: 2
    Last Post: 11-29-2009, 12:00 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums