aboutsummaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorBonfaceKilz2022-02-16 16:48:36 +0300
committerBonfaceKilz2022-03-12 15:33:01 +0300
commit16276bd6a158d7190f50e6a83ad736b335cdc567 (patch)
tree40749c36ca7582d5e1bb801debefb54dc7770e84 /doc
parent578684c741c1b90576f775075d858c224869c699 (diff)
downloadgenenetwork2-16276bd6a158d7190f50e6a83ad736b335cdc567.tar.gz
doc: Update query for fetching case attribute data
* doc/database.org: Also join on StrainId for case-attribute data.
Diffstat (limited to 'doc')
-rw-r--r--doc/database.org3
1 files changed, 2 insertions, 1 deletions
diff --git a/doc/database.org b/doc/database.org
index 99d2905a..32f1f8e0 100644
--- a/doc/database.org
+++ b/doc/database.org
@@ -1386,7 +1386,8 @@ JOIN Strain st ON pd.StrainId = st.Id
LEFT JOIN PublishSE ps ON ps.DataId = pd.Id AND ps.StrainId = pd.StrainId
LEFT JOIN NStrain ns ON ns.DataId = pd.Id AND ns.StrainId = pd.StrainId
LEFT JOIN CaseAttributeXRefNew cxref ON
- cxref.InbredSetId = px.InbredSetId
+ (cxref.InbredSetId = px.InbredSetId AND
+ cxref.StrainId = st.Id)
LEFT JOIN CaseAttribute ca ON ca.Id = cxref.CaseAttributeId
WHERE px.Id = 10006 AND px.PhenotypeId = 28409 LIMIT 10;
#+end_src