I have a table called lets say Table1 with the following columns
ItemID, Priority, Amount
The same ItemID may have multiple entries in the table each with a different priority #
The amount column is a number representing a percentage 0.00 through 100.00
What I need to do is list the ItemIDs where the lowest priority has an amount of 100
and another entry exists for that itemID
Here is some sample data. If the query works correctly it should return ItemID's 5 & 7.
ItemID.....Priority.....Amount
5..........1............100
5..........2............20
6..........1............50
6..........2............50
7..........5............100
7..........7............40
ItemID, Priority, Amount
The same ItemID may have multiple entries in the table each with a different priority #
The amount column is a number representing a percentage 0.00 through 100.00
What I need to do is list the ItemIDs where the lowest priority has an amount of 100
and another entry exists for that itemID
Here is some sample data. If the query works correctly it should return ItemID's 5 & 7.
ItemID.....Priority.....Amount
5..........1............100
5..........2............20
6..........1............50
6..........2............50
7..........5............100
7..........7............40