Skip to content

Commit

Permalink
ZFIN-9444 fix WashZU accession and have them show the defline plus se…
Browse files Browse the repository at this point in the history
…quence when clicking on them
  • Loading branch information
cmpich committed Dec 18, 2024
1 parent 3d8a2f2 commit 39587cc
Show file tree
Hide file tree
Showing 3 changed files with 48 additions and 19 deletions.
20 changes: 1 addition & 19 deletions lib/DB_functions/get_dblink_acc_num_display.sql
Original file line number Diff line number Diff line change
Expand Up @@ -32,25 +32,7 @@ CREATE OR REPLACE FUNCTION "public"."get_dblink_acc_num_display"("dblinkfdbconti
and fdb_db_pk_id = fdbcont_fdb_db_id;


if (dblinkDbName = 'WashUZ') then
-- we need to prepend 'wz' to the acc_num
dblinkAccNumDisplay := 'wz' || dblinkAccNum;

--replace the miranda acc num with one that looks more like the
--way curators want to display miRNA names at ZFIN.
--ZDB-FDBCONT-090529-1, dre-let-7g
--execute function
--get_dblink_acc_num_display('ZDB-FDBCONT-090529-1','dre-let-7g')

else

-- we need to prepend 'wz' to the acc_num

-- spew out exactly what came in
dblinkAccNumDisplay = dblinkAccNum;

end if;

dblinkAccNumDisplay = dblinkAccNum;
return dblinkAccNumDisplay;
end

Expand Down
46 changes: 46 additions & 0 deletions source/org/zfin/db/postGmakePostloaddb/1165/ZFIN-9444.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
--liquibase formatted sql
--changeset cmpich:ZFIN-9444.sql

insert into foreign_db_contains_display_group_member
(fdbcdgm_fdbcont_zdb_id, fdbcdgm_group_id, fdbcdgm_can_view, fdbcdgm_can_add, fdbcdgm_can_edit, fdbcdgm_can_delete)
values ('ZDB-FDBCONT-040412-31', 12, true, true, true, true);

create temp table id
(
id text
);

insert into id
select get_id('BLASTDB');

insert into blast_database
(blastdb_zdb_id, blastdb_name, blastdb_abbrev, blastdb_description, blastdb_public,
blastdb_type, blastdb_tool_display_name,
blastdb_is_being_processed, blastdb_origination_id)
select id,
'Published RNA Washington',
'wz_est',
'EST sequences curated by ZFIN staff from publications.',
false,
'nucleotide',
'Published RNA',
false,
2
from id;

update foreign_db_contains
set fdbcont_primary_blastdb_zdb_id = (select id from id)
where fdbcont_zdb_id = 'ZDB-FDBCONT-040412-31';

update foreign_db
set fdb_db_query = '/action/blast/display-sequence?accession='
where fdb_db_name = 'WashUZ';

update db_link
set dblink_acc_num = db_link.dblink_acc_num_display
where dblink_fdbcont_zdb_id = 'ZDB-FDBCONT-040412-31';

update db_link
set dblink_acc_num = db_link.dblink_acc_num_display,
dblink_info = dblink_info || ', added prefix wz to accession '||CURRENT_DATE
where dblink_fdbcont_zdb_id = 'ZDB-FDBCONT-040412-31';
1 change: 1 addition & 0 deletions source/org/zfin/sequence/blast/Database.java
Original file line number Diff line number Diff line change
Expand Up @@ -177,6 +177,7 @@ public static enum AvailableAbbrev {
ZFIN_MICRORNA("zfin_microRNA"),
ZFIN_MIRNA_STEMLOOP("zfin_miRNA_stemloop"),
ZFIN_MIRNA_MATURE("zfin_miRNA_mature"),
WZ_EST("wz_est"),
ZFIN_MRPH("zfin_mrph"),
ZFIN_TALEN("zfin_talen"),
ZFIN_CRISPR("zfin_crispr"),
Expand Down

0 comments on commit 39587cc

Please sign in to comment.