string(5) "11293"
are_locs_open_to_public: string(766) "SELECT DISTINCT species.*,
media.Species_ID AS 'has_media'
FROM Maryland_Species species
LEFT JOIN (
SELECT DISTINCT Species_ID
FROM Media
WHERE NeedsReview = 0 AND Photographer_ID = :user
) media ON species.Species_ID = media.Species_ID
JOIN (
SELECT DISTINCT Species_ID
FROM MDB_Records
WHERE IsDisplayed = 1 AND Person_ID = :user
) records ON species.Species_ID = records.Species_ID
WHERE species.Species_ID NOT IN (
SELECT DISTINCT records.Species_ID
FROM MDB_Records records
JOIN MDB_Tag_Species_Map tag_species_map ON records.Species_ID = tag_species_map.Species_ID
JOIN MDB_Tags tags ON tag_species_map.TagID = tags.TagID
WHERE TagName = 'Vulnerable'
)
ORDER BY Kingdom, Class, OrderName, Family, Genus, Species"