Everything I have read says that the only thing that matters is the best five cards you use for your hand. However, I was in a friendly game when this scenario came up.

player1: Q,7
player2: Q,6
board:Q,3,2,2,9

So.....does the Q,7 take it or do they split the pot?