The board shows two queens, a 9, 8, and 7. I'm holding a queen and a Jack. The other player is holding a queen and an Ace. Is this a split pot or does the Ace play?
You and your opponent both have "trip" queens. Then the side cards, or kickers, decide the issue.
Your opponent has a side ace, and you have a side jack, both of which are higher than the nine on the board. So the ace plays. So does your jack, but aces "outkick" jacks. That is, you have QQQJ9, and your opponent has QQQA9 for a better hand. If your opponent's ace were a ten, you would have the better kicker and hand against QQQT9.
Change his ace to a six, and your jack to a five. Then the board plays, and you each have QQQ98. The fact that his six beats your five doesn't matter, because it's lower than the lowest board card (8) that plays, and this would be a split pot. The ones in the previous paragraph would not be.