IMPORT get_organism_id(TEXT) FROM organism;
IMPORT get_feature_type_id(TEXT) FROM 'sequence-cv-helper';

DECLARE FUNCTION get_feature_id(uniquename VARCHAR,
                                type       VARCHAR,
                                organism   VARCHAR) RETURNS INT;
COMMENT ON FUNCTION get_feature_id(VARCHAR,VARCHAR,VARCHAR) IS 'returns feature_id based on uniquename type organism. Type is assumed to be from sequence ontology. Organism is a binomial string';
EXAMPLE SELECT get_feature_id('2L','chromosome_arm','Drosophila melanogaster');
