An Error Was Encountered

Error Number: 1064

You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'count(DISTINCT(bold_images.name)) as barcode_num FROM bold_data ' at line 1

SELECT bold_data.,count(DISTINCT(bold_images.name)) as barcode_num FROM bold_data LEFT JOIN bold_images ON bold_data.id = bold_images.taxa_key WHERE bold_images.barcodes > 0 GROUP BY