The whole point of 4th generation languages is to do things like this. You can do much of it in Excel, but that's like fixing your car with a crescent wrench. What you're describing is "select where" functionality. Nothing beats SQL for this, and it is one of the simplest of tasks that you can do with it. You can do some very, very complicated data manipulation with just a few lines of SQL. I'm no SQL expert, but problems like these are why it was invented.

FWIW,
Jim