Locality: (40.659400, -74.038390)
Abstract: INSERT INTO fmchklsttaxalink(tid, clid) SELECT cl.tid, 5126 as clid FROM omoccurrences o INNER JOIN taxstatus ts ON o.tidinterpreted = ts.tid INNER JOIN taxa t ON ts.tidaccepted = t.tid INNER JOIN taxstatus ts2 ON ts.tidaccepted = ts2.tidaccepted INNER JOIN fmchklsttaxalink cl ON ts2.tid = cl.tid WHERE o.stateprovince = "New York" AND ts.taxauthid = 1 AND ts2.taxauthid = 1 AND t.rankid > 219 AND cl.clid = 5058 AND (o.county LIKE "New York%" OR o.county LIKE "king%" OR o.county LIKE "queens%" OR o.county LIKE "bronx%" OR o.county LIKE "Richmond%") AND (o.cultivationstatus IS NULL OR o.cultivationstatus != 1) GROUP BY t.tid HAVING count(o.occid) = 1; INSERT INTO fmchklsttaxalink(tid, clid) SELECT cl.tid, 5126 as clid FROM fmchklsttaxalink cl INNER JOIN taxa t2 ON cl.tid = t2.tid WHERE cl.clid = 5058 AND t2.rankid > 219 AND cl.tid NOT IN(SELECT cl.tid FROM omoccurrences o INNER JOIN taxstatus ts ON o.tidinterpreted = ts.tid INNER JOIN taxa t ON ts.tidaccepted = t.tid INNER JOIN taxstatus ts2 ON ts.tidaccepted = ts2.tidaccepted INNER JOIN fmchklsttaxalink cl ON ts2.tid = cl.tid WHERE o.stateprovince = "New York" AND ts.taxauthid = 1 AND ts2.taxauthid = 1 AND t.rankid > 219 AND cl.clid = 5058 AND (o.county LIKE "New York%" OR o.county LIKE "king%" OR o.county LIKE "queens%" OR o.county LIKE "bronx%" OR o.county LIKE "Richmond%") AND (o.cultivationstatus IS NULL OR o.cultivationstatus != 1));
Notes: Generated from central vascular checklist version Aug 2017