Skip to content
Snippets Groups Projects
Commit fdaa21b4 authored by tjc's avatar tjc
Browse files

changes for updating feature residues in the database

git-svn-id: svn+ssh://svn.internal.sanger.ac.uk/repos/svn/pathsoft/artemis/trunk@10380 ee4ac58c-ac51-4696-9907-e4b3aa274f04
parent cfaf63fb
No related branches found
No related tags found
No related merge requests found
......@@ -485,7 +485,11 @@
</dynamic>
substring(residues from $endBase$ for $basesToEnd$),
seqlen=$seqLen$
WHERE feature_id=$featureId$
WHERE
<isNotEqual property="featureId" compareValue="-1">feature_id=$featureId$</isNotEqual>
<isEqual property="featureId" compareValue="-1">
feature_id=(SELECT feature_id FROM feature WHERE uniquename=#uniqueName#)
</isEqual>
</update>
<!-- INSERT -->
......@@ -494,6 +498,7 @@
INSERT INTO feature
( feature_id, organism_id, name, uniquename, type_id
<isGreaterThan property="seqLen" compareValue="0"> , seqlen </isGreaterThan>
<isNotNull property="residues"> , residues </isNotNull>
<isNotNull property="dbXRef.dbXRefId"> , dbxref_id </isNotNull> )
VALUES
( nextval('feature_feature_id_seq'),
......@@ -502,6 +507,7 @@
#uniqueName#,
$cvTerm.cvTermId$
<isGreaterThan property="seqLen" compareValue="0"> , $seqLen$ </isGreaterThan>
<isNotNull property="residues"> , #residues# </isNotNull>
<isNotNull property="dbXRef.dbXRefId"> , $dbXRef.dbXRefId$ </isNotNull> )
</insert>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment