<?xml version="1.0" encoding="UTF-8"?>

<!-- <!DOCTYPE sddlschema SYSTEM "sddlschema.xsd">-->

<sddl>

<!-- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -->
<!-- -->
<!--  SDDL Name:  MSC_AST_OBSERVE.SDDL -->
<!-- -->
<!--  Purpose:      This SDDL file defines the MSC_AST_OBSERVE relation.-->
<!-- -->
<!--  Modification History:-->
<!-- -->
<!--    Date       PR      Who                       Reason-->
<!--  - - - -    - - - -   - -    - - - - - - - - - - - - - - - - - - - - - -->
<!--  05/31/00   44862     Baum   Original implementation-->
<lm>  07/03/03   48821     CTB   Converted to XML format </lm> <!-- last mod -->
<!-- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -->
 

    <record name="MSC_AST_OBSERVE_TYPE"> 
 
 
        <description>This relation is used to contain the observation data for
                   astrometry. The event time is taken from the time found in
                   the MSC file but there is no msc_events record for this
                   event. The fields are used to set astrometry keywords. </description>


            <field name="event_time">
                    <type>C20</type>
                    <description>YYYY.DDD.HH.MM.SS.CC the time within a hundreth of
                         a second for each obset. </description>
            </field>

            <field name="program_id">
                    <type>C3</type>
                    <units>BASE_36</units>
                    <description>When a proposal is accepted into the PMDB by SPSS it must
		    be assigned a unique 3 character base 36 program identifier.
		    This is done by the PMDB/ACCEPT_PROP command.
                    It is used for identification of proposals by spacecraft 
                    and OPUS software. It is also used in the OPUS and DADS 
                    rootname for all archived science data files. 
                    Because of flight design software, program_id must be
                    three characters. </description>
            </field>

            <field name="obset_id">
                    <type>C2</type>
                    <units>BASE_36</units>
                    <description>An observation set is a collection of one or more 
		    alignments that are grouped together based on FGS pointing 
		    requirements.  That is, if multiple alignments can all be 
		    executed using the same guide star pair, they are grouped
		    into the same observation set. </description>
            </field>

            <field name="ob_number">
                    <type>C2</type>
                    <units>BASE_36</units>
                    <description>Observations are numbered sequentially throughout
                    an observation set and are assigned by SMS/Gen.
                    An ob_number is _NOT_ the same as an obset_ID. </description>
            </field>

            <field name="fgs">
                    <type>C1</type>
                    <description>FGS number, 1 2 or 3, or 0 for all.</description>
            </field>

            <field name="param_name">
                    <type>C8</type>
                    <description>Keyword name or keyword related parameter name.</description>
            </field>

            <field name="param_value">
                    <type>C20</type>
                    <description>Formatted value of parameter.</description>
            </field>


    </record>
 
  
 
    <relation name="msc_ast_observe">
 
        <type>MSC_AST_OBSERVE_TYPE</type>

        <description>Astrometry observation keyword data from MSC file</description>

        <subsystem_using>OPUS</subsystem_using>

        <index name="msc_ast_observe_1">
            <type>unique clustered</type>
            <field name="event_time"/>
            <field name="program_id"/>
            <field name="obset_id"/>
            <field name="ob_number"/>
            <field name="fgs"/>
            <field name="param_name"/>
        </index>

        <index name="msc_ast_observe_2">
            <type>nonclustered</type>
            <field name="program_id"/>
            <field name="obset_id"/>
            <field name="ob_number"/>
            <field name="fgs"/>
            <field name="param_name"/>
        </index>

    </relation>
</sddl>
