File: sequence-loading.sqlapi

package info (click to toggle)
libchado-perl 1.23-2
  • links: PTS, VCS
  • area: main
  • in suites: jessie, jessie-kfreebsd
  • size: 23,976 kB
  • ctags: 10,378
  • sloc: xml: 192,540; sql: 165,945; perl: 28,339; sh: 101; python: 73; makefile: 46
file content (47 lines) | stat: -rw-r--r-- 1,704 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
DECLARE FUNCTION store_feature
( srcfeature_id       INT,
  fmin                INT,
  fmax                INT,
  strand              INT,
  dbxref_id           INT,
  organism_id         INT,
  name                VARCHAR,
  uniquename          VARCHAR,
  type_id             INT,
  is_analysis         BOOLEAN)
RETURNS INT;

COMMENT ON FUNCTION store_feature (INT,INT,INT,INT,
INT,INT,VARCHAR,VARCHAR,INT,BOOLEAN) RETURN INT IS 'stores a feature and its featureloc. The featureloc is assumed to be primary (rank and locgroup=0). Performs UPDATE on feature if either (dbxref_id) or (uniquename,organism_id,type_id) correspond to a row in the database, INSERTs otherwise. Will replace any existing primary featureloc';

DECLARE FUNCTION store_featureloc
( feature_id          INT,
  srcfeature_id       INT,
  fmin                INT,
  fmax                INT,
  strand              INT,
  rank                INT,
  locgroup            INT);
RETURNS INT;

COMMENT ON FUNCTION store_featureloc (INT,INT,INT,INT,INT,INT,INT)
RETURNS INT AS 'stores the featureloc for a given feature. If a
featureloc with the same (feature_id,rank,locgroup) exists, will
replace - otherwise inserts new featureloc';

DECLARE FUNCTION store_feature_synonym
( feature_id          INT,
  syn                 VARCHAR,
  type_id             INT,
  is_current          BOOLEAN,
  is_internal         BOOLEAN,
  pub_id              INT)
RETURN INT;

COMMENT ON FUNCTION store_feature_synonym
(INT,VARCHAR,INT,BOOLEAN,BOOLEAN,INT) RETURNS INT IS 'stores a synonym
and feature_synonym link for a given feature. inserts new synonym if
not present. if feature_synonym link exists for this synonym, will
update the boolean flags';