I need to eliminate a record with almost exactly the same data except 1...for example:

I have 4 Fields for Employee table:

Employee Stat First Name Last Name Employee ID
Active James Smith JOS
Resigned James Smith JOS

For some reason the table I'm querying has these data. How can I query wherein, if a specific employee has 2 data, I'll just get the active. I guess this happens when an old employee come back to the company and didn't just change the data stat but create a new one.

You can just add it to the where clause

SELECT * FROM Employee WHERE EmployeeStat = 'Active'
Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.