NAME

load_proc_parse.pl - Update the Sybase starcheck processing tables


SYNOPSIS

load_proc_parse.pl [ mission planning directory ]


OPTIONS

-help
print this usage and exit

-dryrun
print retrieved information to screen, no changes to database

-missing
sets the list of to-be-parsed folders to include any folder that exists in the mp_load_info table but does not exist in the starcheck_processing table

-log logfilename
write processing information and warnings to file logfilename


DESCRIPTION

This script populates a database that stores all of the load-specific (but not obsid-specific) information from starcheck.txt. When called without any options, the script queries the mp_load_info table to get a list of all load directories that have newer ``processed dates'' than the dates already within the starcheck_processing table. The data from the starcheck files within those directories are then added to the starcheck_processing table. If the script is run on a directory that already exists within the table (either reprocessed in automatic processing and hence updated in the mp_load_info table, or specified at the command line), the old information is deleted and a new entry is created.


DATABASE COLUMNS

starcheck_processing

 name                                               type       length     
 -------------------------------------------------- ---------- -----------
 mp_path                                            varchar             30
 type                                               varchar             30
 value                                              varchar            100
 section_line_num                                   intn                 4
 last_ap_date                                       datetimn             8
    This table is actually a bit confusing; each section of the
    starcheck header matter is parsed individually and each line
    within each section is numbered.  This allows one to use the
    database to conveniently search for items and the line numbers allow a user to use
    the table to reconstruct much of the original starcheck output.


EXAMPLES

This script should be run in an overnight cron job with no input parameters.


AUTHOR

Jean Connelly, <jeanconn@localdomain>


COPYRIGHT AND LICENSE

Copyright 2006 by Smithsonian Astrophysical Obsevatory

This script is free software; you can redistribute it and/or modify it under the same terms as Perl itself.