Join 2 "select" functions need help I'm very new!

Hello! I’m very self taught and don’t know what I’m doing. I have checked a few threads on this webpage and I have ended up with the following. I have 4 select functions being ran and I want to combine their result. I will list 2 and show what amalgamation I have created with a third. All of the lines run perfectly on their own using seperate functions - however they return a list with many duplicates. I am trying to make no duplicates exist by combining the selects into 1 select.

1. this is a select line that pulls exact first name, last, name, and zip matches.
$sql = sprintf(“select * from bidder where auctioneer_id = "%s" AND zip = "$zip" AND last_name = "$last_name" AND first_name = "$first_name" ORDER BY last_name ASC, first_name ASC”, $auctioneer_id, $first_name, $zip);

2. this is a select line that pulls all first name matches.
$sql = sprintf(“select * from bidder where auctioneer_id = "%s" AND first_name = "%s" ORDER BY last_name ASC, first_name ASC”, $auctioneer_id, $first_name);

3. what my hubris has brought me to; it pulls all exact license number matches and correctly displays them but shows no other entries.
if($license_number != “”)
$sql = sprintf(“select * from bidder where auctioneer_id = "%s" AND license_number = "$license_number" UNION ALL select * from bidder where auctioneer_id = "%s" AND zip = "$zip" AND last_name = "$last_name" AND first_name = "$first_name" UNION ALL select * from bidder where auctioneer_id = "%s" AND first_name = "%s" ORDER BY last_name ASC, first_name ASC”, $auctioneer_id, $first_name, $license_number, $zip);