[ensembl-dev] Trouble finding display name in core schema
Stefano Giorgetti
sgiorgetti at ebi.ac.uk
Tue Mar 1 07:26:13 GMT 2022
Hello Laura,
Thanks for your email.
The "display_name" is referenced to by the field "display_xref_id" in
either gene or transcript table, and you can find the actual
"display_name" in the xref table.
For example, let's assume we are interested in the gene identified by
"ENSG00000139618", the following SQL query shows you the "display_name"
SELECT g.gene_id, g.stable_id, g.biotype, g.display_xref_id,
x.external_db_id, e.db_name, x.display_label
FROM gene g INNER JOIN xref x ON g.display_xref_id = x.xref_id
INNER JOIN external_db e ON x.external_db_id =
e.external_db_id
WHERE g.stable_id = 'ENSG00000139618';
A similar query can work on transcripts; for example
SELECT t.gene_id, t.stable_id, t.biotype, t.display_xref_id,
x.external_db_id, e.db_name, x.display_label
FROM transcript t INNER JOIN xref x ON t.display_xref_id = x.xref_id
INNER JOIN external_db e ON x.external_db_id =
e.external_db_id
LIMIT 5;
In both the examples, I added in the "external_db" table to show where
the "display_name" comes from.
This is entirely optional, and you can safely remove table and related
field from the queries.
Hope this helps.
Best wishes,
Stefano
On 01/03/2022 03:08, Luebbert, Laura wrote:
>
> Hi,
>
> I am having trouble finding the equivalent of the “display_name” (name
> or identifier of a gene/transcript) in the Ensembl core schema. In
> which table can I find this information for each stable ID?
>
> With best regards,
>
> Laura
>
>
> _______________________________________________
> Dev mailing listDev at ensembl.org
> Posting guidelines and subscribe/unsubscribe info:https://lists.ensembl.org/mailman/listinfo/dev_ensembl.org
> Ensembl Blog:http://www.ensembl.info/
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.ensembl.org/pipermail/dev_ensembl.org/attachments/20220301/462466c8/attachment.html>
More information about the Dev
mailing list