Results 1 to 3 of 3

Thread: How to check input ID

  1. #1

    Thread Starter
    Junior Member
    Join Date
    Feb 2001
    Location
    Xiamen
    Posts
    22

    How to check input ID

    I want to make sure if the input ID has been in the databas. I use SQL to find a record which ID is same as inputID. But it takes time. Is there any faster way to check the input ID?
    Looking forward

  2. #2
    Hyperactive Member Ed Lampman's Avatar
    Join Date
    Mar 2001
    Posts
    273
    To make your query as fast as possible, make sure the ID field is indexed in the db.

  3. #3
    Member
    Join Date
    Feb 2001
    Location
    St. Louis, Missouri
    Posts
    49
    What program was the database created in?

    If it was created in Access there is a feature where you can specify that duplicates are not allowed for a field. Then, in the sub where you were using SQL just put an error handler that displays a message box 'Duplicates are not allowed' or some such and exit the sub.

    Hope that helps.

    Eva

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