IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 35227 for trunk/ippTools/share


Ignore:
Timestamp:
Mar 4, 2013, 2:08:07 PM (13 years ago)
Author:
bills
Message:

updates to release tables. This version was used to create the
tables in gpc1

Location:
trunk/ippTools/share
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/ippTools/share/pxadmin_create_tables.sql

    r35213 r35227  
    21532153
    21542154CREATE TABLE survey (
    2155     surveyID    INT(8),
     2155    surveyID    INT,
    21562156    surveyName  VARCHAR(16) NOT NULL,
    21572157    description VARCHAR(255),
    21582158    PRIMARY KEY(surveyID),
    2159     UNIQUE  KEY(name)
     2159    UNIQUE  KEY(surveyName)
    21602160) ENGINE=InnoDB CHARSET=latin1;
    21612161
    2162 
    21632162CREATE TABLE ippRelease (
    2164     rel_id      INT(8) AUTO_INCREMENT,
    2165     surveyID    INT(8),
     2163    rel_id      INT AUTO_INCREMENT,
     2164    surveyID    INT,
    21662165    release_name VARCHAR(64),
    2167     relase_state VARCHAR(16),   -- active, pending, archive, drop
    2168     dataRelease INT(8),         -- PSPS dataRelease
    2169     priority    INT(8),
     2166    release_state VARCHAR(16),   -- active, pending, archive, drop
     2167    dataRelease INT,         -- PSPS dataRelease
     2168    priority    INT,
    21702169    PRIMARY KEY(rel_id),
    21712170    KEY(release_name),
    2172     KEY(state),
     2171    KEY(release_state),
    21732172    KEY(priority),
    21742173    FOREIGN KEY(surveyID) REFERENCES survey(surveyID)
     
    21772176CREATE TABLE relExp (
    21782177    relexp_id   BIGINT AUTO_INCREMENT,
    2179     rel_id      INT(8),
     2178    rel_id      INT,
    21802179    exp_id      BIGINT,
    21812180    chip_id     BIGINT,         -- links to the runs that supplied the data
    21822181    cam_id      BIGINT,         -- for this release
    2183     group_id    INT(8),         -- id of relGroup that this exposure is contained in
     2182    group_id    INT,         -- id of relGroup that this exposure is contained in
    21842183    state       VARCHAR(16),    -- released, pending, archive, drop 
    2185     flags       INT UNSIGNED,   -- flags for relphot, relastro, ??
     2184    flags       INT UNSIGNED,  -- flags for relphot, relastro, ??
    21862185    zpt_obs     FLOAT,          -- calibrated zero point for this release of
    21872186    zpt_stdev   FLOAT,          -- this exposure
     
    22022201CREATE TABLE relStack (
    22032202    relstack_id BIGINT AUTO_INCREMENT,
    2204     rel_id      INT(8),
     2203    rel_id      INT,
    22052204    stack_id    BIGINT,         -- id of the stackRun
    22062205    skycal_id   BIGINT,         -- id of the sky calibration run that supplied the calibration
     
    22142213    zpt_obs     FLOAT,          -- calibrated zero point for this release of this skycell
    22152214    zpt_stdev   FLOAT,
    2216     mjd_obs     INT UNSIGNED,   -- for nightly stacks the mjd_obs
     2215    mjd_obs     INT UNSIGNED,   -- for nightly stacks the mjd_obs, zero for deep and reference
    22172216    path_base   VARCHAR(255),   -- path_base of any supporting files,
    22182217    fault SMALLINT NOT NULL,
     
    22312230
    22322231CREATE TABLE relGroup (
    2233     group_id    INT(8) AUTO_INCREMENT,
    2234     rel_id      INT(8),
     2232    group_id    INT AUTO_INCREMENT,
     2233    rel_id      INT,
    22352234    group_type  VARCHAR(16),
    22362235    lap_id      BIGINT,
     
    22522251) ENGINE=innodb DEFAULT CHARSET=latin1;
    22532252
     2253CREATE TABLE lapGroup  (
     2254    seq_id  BIGINT,
     2255    projection_cell VARCHAR(64),
     2256    state   VARCHAR(16),
     2257    fault   SMALLINT,
     2258    PRIMARY KEY(seq_id, projection_cell),
     2259    KEY(state),
     2260    KEY(fault),
     2261    FOREIGN KEY(seq_id) REFERENCES lapSequence(seq_id)
     2262) ENGINE=innodb DEFAULT CHARSET=latin1;
     2263
    22542264
    22552265
  • trunk/ippTools/share/pxadmin_drop_tables.sql

    r34913 r35227  
    109109DROP TABLE IF EXISTS skycalResult;
    110110DROP TABLE IF EXISTS skycell;
     111DROP TABLE IF EXISTS relStack;
    111112DROP TABLE IF EXISTS relExp;
     113DROP TABLE IF EXISTS relGroup;
    112114DROP TABLE IF EXISTS ippRelease;
    113115DROP TABLE IF EXISTS survey;
     116DROP TABLE IF EXISTS lapGroup;
    114117
    115118SET FOREIGN_KEY_CHECKS=1
Note: See TracChangeset for help on using the changeset viewer.