Need Help on Access Form - Duplicate Entry Restriction (1 Viewer)

srinayana

New member
Local time
Today, 08:19
Joined
Dec 7, 2009
Messages
3
Hi Team,

I have a Form created for Hardware Allocation.
I have following Fields. Allocation ID(PK), HW ID, User ID, HW Status, Assigned Date.

Values of HW Status = Active, Inactive, Decom, In Stock etc.

What I want is explaind below example
HW XXX is allocated to User ABC and the Status is Active.
Now When I want to reallocate the same HW XXX to Another User XYZ then Make the current status as Active. But before doing that the form should force me to change the Status of previous allocated to user ABC to anything other than active. Because One Device can be active to only one user at a time.

i,e Combination of HW ID & HW Status(Active Only) should not be duplicated.

Your help is appreciated in advance.
 

Mihail

Registered User.
Local time
Today, 17:19
Joined
Jan 22, 2011
Messages
2,373
Use "Indexes" at table level in order to not allow duplicates on fields User-Device-Status
 

Users who are viewing this thread

Top Bottom