i need help writting a sql query that will select rows only when more that one occurance of the value in a column occurs. in my case, i need to select rows when there is more than one occurance of the same tracking number.
So if i had a small database with a table called billing with 6 rows and the value of the column "tracking number" was as follows (1, 2, 3, 2, 3, 3), i would want the query to return 5 rows - 2,3,2,3,3.
Additionally, i need another query that does just the opposite - returns 1 row - 1.
I've tried several attemplts at inner joins without much luck.