IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 35064


Ignore:
Timestamp:
Jan 28, 2013, 6:28:59 AM (13 years ago)
Author:
eugene
Message:

adding functions to insert from master, not client

Location:
branches/eam_branches/ipp-20121219/Ohana/src/dvopsps
Files:
1 added
2 edited

Legend:

Unmodified
Added
Removed
  • branches/eam_branches/ipp-20121219/Ohana/src/dvopsps/include/dvopsps.h

    r35055 r35064  
    66# define DVO_MAX_PATH 1024
    77# define MAX_BUFFER 0x080000
     8
     9typedef struct {
     10    int imageID;
     11    unsigned int ippDetectID;
     12    uint64_t detectID;
     13    uint64_t ippObjID;
     14    uint64_t objID;
     15    unsigned int flags;
     16    float zp;
     17    float zpErr;
     18    float airMass;
     19    float expTime;
     20    double ra;
     21    double dec_;
     22    float raErr;
     23    float decErr;
     24} Detections;
    825
    926/* global variables set in parameter file */
  • branches/eam_branches/ipp-20121219/Ohana/src/dvopsps/src/insert_detections_dvopsps.c

    r35055 r35064  
    6767
    6868    // NOTE: this is where the real action happens
    69     insert_detections_dvopsps_catalog (&catalog, mysqlReal);
     69    if (1) {
     70        insert_detections_dvopsps_catalog (&catalog, mysqlReal);
     71    } else {
     72        // NOTE: this is where the real action happens
     73        save_detections_dvopsps_catalog (&catalog, "???");
     74    }
    7075
    7176    // NOTE : unlike setastrom or relphot, this program is read-only wrt dvo
     
    153158  }
    154159
     160# if (0)
     161  for (i = 0; i < table->Nhosts; i++) {
     162    while ((detections = RemoteDetectionsLoad (table->hosts[i].results)) == NULL) {
     163      // failed to get the data from this host.  This can happen for various reasons.  Give the user a chance to try again...
     164      fprintf (stderr, "failed to read data from %s\n", table->hosts[i].hostname);
     165      fprintf (stderr, "you may run the command manually\n");
     166    }
     167    free (table->hosts[i].results);
     168    table->hosts[i].results = NULL;
     169   
     170    RemoveDetectionsInsert (detections);
     171
     172    free (detections);
     173  }
     174# endif
     175
    155176  return (TRUE);
    156177}     
Note: See TracChangeset for help on using the changeset viewer.