×
INTELLIGENT WORK FORUMS
FOR COMPUTER PROFESSIONALS

Contact US

Log In

Come Join Us!

Are you a
Computer / IT professional?
Join Tek-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!

*Tek-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

Create New Table From Oracle ODBC

Create New Table From Oracle ODBC

Create New Table From Oracle ODBC

(OP)
I have setup a table in Access that when the switchboard form opens, it deletes all records and updates the table with current information. It works find.  My only problem is that my index (Employee Number) is supposed to be unique, but there are two records out there that are duplicates because the staff person is covering two positions.

The table is based on a query.  How do I get the query to skip the duplicate records, based on the employee number?

Thanks,
Basia

RE: Create New Table From Oracle ODBC

You could use the Unique properties of the query to pull only the proper people over.  There are two of them:


Unique Record:  All fields in that record is compared against others for uniqueness.
Unique Value:  All fields selected in the QBE grid are compared against other for uniqueness.


If you need more help, try looking up Unique Values in help.

Joe Miller
joe.miller@flotech.net

RE: Create New Table From Oracle ODBC

(OP)
Thanks for getting back to me.  Unfortunately this options are not catching the duplicate records since other data in the record is different.  I need to have the Unique function look at a specific field.  Any thoughts?

RE: Create New Table From Oracle ODBC

Make a query that has only the fields needed to determine a unique record.  Then in the query you currently have relate the query with the unique records to the key field, then you'll only get the records that are unique.

Regards.

Joe Miller
joe.miller@flotech.net

RE: Create New Table From Oracle ODBC

(OP)
Thanks!

Basia

RE: Create New Table From Oracle ODBC

If the employee number is supposed to be unique then proper design would have it as the Primary Key.  A second table containing the positions they fill would have a foreign key (EmpID) that would relate to the employee number.

EMPTABLE
   EmpID   Long    Primary Key
   EmpName Text

POSITION
   PosID   Long    Primary Key
   PosName Text    
   EmpID   Long    Foreign Key


This implements a one-many relationship using proper relational design techniques and prevents you from writing special code, looking in a single field, and managing the result uniquely.

Steve King

Growth follows a healthy professional curiosity

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Tek-Tips Forums free from inappropriate posts.
The Tek-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Tek-Tips forums is a member-only feature.

Click Here to join Tek-Tips and talk with other members! Already a Member? Login

Close Box

Join Tek-Tips® Today!

Join your peers on the Internet's largest technical computer professional community.
It's easy to join and it's free.

Here's Why Members Love Tek-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close