CloneSet270


Previous CloneSetNext CloneSetBack to Main Report
Clone
Mass
Clones in
CloneSet
Parameter
Count
Clone
Similarity
Syntax Category
[Sequence Length]
16260.956compound_stmt
Clone AbstractionParameter Bindings
Clone Instance
(Click to see clone)
Line CountSource Line
Source File
116962
BioSQL/Loader.py
2161013
BioSQL/Loader.py
Clone Instance
1
Line Count
16
Source Line
962
Source File
BioSQL/Loader.py

    def _get_seqfeature_dbxref(self,seqfeature_id,dbxref_id,rank):   
        """ Check for a pre-existing seqfeature_dbxref entry with the passed
            seqfeature_id and dbxref_id.  If one does not exist, insert new
            data

        """ 
        # Check for an existing record
        sql = "SELECT seqfeature_id, dbxref_id FROM seqfeature_dbxref "
              "WHERE seqfeature_id = '%s' AND dbxref_id = '%s'" 
        result = self.adaptor.execute_and_fetch_col0(sql,(seqfeature_id,dbxref_id)) 

        # If there was a record, return without executing anything, else create
        # the record and return
        if result: 
             return result 
        return self._add_seqfeature_dbxref(seqfeature_id,dbxref_id,rank) 


Clone Instance
2
Line Count
16
Source Line
1013
Source File
BioSQL/Loader.py

    def _get_bioentry_dbxref(self,bioentry_id,dbxref_id,rank):   
        """ Check for a pre-existing bioentry_dbxref entry with the passed
            seqfeature_id and dbxref_id.  If one does not exist, insert new
            data

        """ 
        # Check for an existing record
        sql = "SELECT bioentry_id, dbxref_id FROM bioentry_dbxref "
              "WHERE bioentry_id = '%s' AND dbxref_id = '%s'" 
        result = self.adaptor.execute_and_fetch_col0(sql,(bioentry_id,dbxref_id)) 

        # If there was a record, return without executing anything, else create
        # the record and return
        if result: 
             return result 
        return self._add_bioentry_dbxref(bioentry_id,dbxref_id,rank) 


Clone AbstractionParameter Count: 6Parameter Bindings

def [[#variable6189e200]](self, [[#variable6189e160]],dbxref_id,rank):
   [[#variable6189e0e0]]
  # Check for an existing record
  sql = [[#variable6189e080]] [[#variable6189e020]]
  result = self.adaptor.execute_and_fetch_col0(sql,( [[#variable6189e160]],dbxref_id)) 
  # If there was a record, return without executing anything, else create
  # the record and return
  if result:
  
    return result 
  return self. [[#variable761d5f80]]( [[#variable6189e160]],dbxref_id,rank) 
 

CloneAbstraction
Parameter Bindings
Parameter
Index
Clone
Instance
Parameter
Name
Value
11[[#6189e200]]
_get_bioentry_dbxref 
12[[#6189e200]]
_get_seqfeature_dbxref 
21[[#6189e160]]
bioentry_id 
22[[#6189e160]]
seqfeature_id 
31[[#6189e0e0]]
""" Check for a pre-existing bioentry_dbxref entry with the passed
            seqfeature_id and dbxref_id.  If one does not exist, insert new
            data

        """ 
32[[#6189e0e0]]
""" Check for a pre-existing seqfeature_dbxref entry with the passed
            seqfeature_id and dbxref_id.  If one does not exist, insert new
            data

        """ 
41[[#6189e080]]
"SELECT bioentry_id, dbxref_id FROM bioentry_dbxref " 
42[[#6189e080]]
"SELECT seqfeature_id, dbxref_id FROM seqfeature_dbxref " 
51[[#6189e020]]
"WHERE bioentry_id = '%s' AND dbxref_id = '%s'" 
52[[#6189e020]]
"WHERE seqfeature_id = '%s' AND dbxref_id = '%s'" 
61[[#761d5f80]]
_add_bioentry_dbxref 
62[[#761d5f80]]
_add_seqfeature_dbxref