Created
July 4, 2017 16:36
-
-
Save jorvis/c0d43d8ac4f16d77bd180446b43d1fb4 to your computer and use it in GitHub Desktop.
Now, how to do with just JOINs?
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SELECT f.feature_id | |
FROM feature f | |
JOIN cvterm ON f.type_id=cvterm.cvterm_id | |
WHERE cvterm.name = 'polypeptide' | |
AND f.feature_id NOT IN ( | |
SELECT f.feature_id | |
FROM feature f | |
JOIN cvterm ON f.type_id=cvterm.cvterm_id | |
JOIN featureprop fp ON f.feature_id=fp.feature_id | |
JOIN cvterm gpn ON fp.type_id=gpn.cvterm_id | |
WHERE cvterm.name = 'polypeptide' | |
AND gpn.name = 'gene_product_name'); | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment