.ad 8
.bm 8
.fm 4
.bt $Copyright by SAP AG, 2000$$Page %$
.tm 12
.hm 6
.hs 3
.tt 1 $SQL$Project Distributed Database System$VKB007$
.tt 2 $$$
.tt 3 $JuergenA$KB7_constants_and_types$2000-08-09$
***********************************************************
.nf


    ========== licence begin  GPL
    Copyright (C) 2000 SAP AG

    This program is free software; you can redistribute it and/or
    modify it under the terms of the GNU General Public License
    as published by the Free Software Foundation; either version 2
    of the License, or (at your option) any later version.

    This program is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    GNU General Public License for more details.

    You should have received a copy of the GNU General Public License
    along with this program; if not, write to the Free Software
    Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
    ========== licence end

.fo
.nf
.sp
Module  : KB7_constants_and_types
=========
.sp
Purpose : Constants and types used within the qual/select modules
.CM *-END-* purpose -------------------------------------
.sp
.cp 3
Define  :
 
.CM *-END-* define --------------------------------------
.sp;.cp 3
Use     :
 
.CM *-END-* use -----------------------------------------
.sp;.cp 3
Synonym :
 
.CM *-END-* synonym -------------------------------------
.sp;.cp 3
Author  : JuergenA
.sp
.cp 3
Created : 1983-07-08
.sp
.cp 3
Version : 2000-08-09
.sp
.cp 3
Release :      Date : 2000-08-09
.sp
***********************************************************
.sp
.cp 10
.fo
.oc _/1
Specification:
 
.CM *-END-* specification -------------------------------
.sp 2
***********************************************************
.sp
.cp 10
.fo
.oc _/1
Description:
 
.CM *-END-* description ---------------------------------
.sp 2
***********************************************************
.sp
.cp 10
.nf
.oc _/1
Structure:
 
.CM *-END-* structure -----------------------------------
.sp 2
**********************************************************
.sp
.cp 10
.nf
.oc _/1
.CM -lll-
Code    :
 
 
CONST
      ckb7_maxdistinctfiles  =   16;
      ckb7_maxnewpos         =  MAX_COL_PER_TAB_GG00 + MAX_JOINS_GG00;
      ckb7_ojoin_none        =    0;
      ckb7_ojoin_left        =    1;
      ckb7_ojoin_right       =    2;
      ckb7_ojoin_full        =    3;
      ckb7_oj_key_offs       =   10;
      ckb7_oj_key_off1       =    7;
 
TYPE
 
      tkb7_distinct_file_info = RECORD
            dfi_root       : tsp_page_no;
            dfi_root_check : tsp00_Int4;
      END;
 
      tkb7_distinct_roots = ARRAY [ 1..ckb7_maxdistinctfiles ]
            OF tkb7_distinct_file_info;
 
      tkb7_select_param = RECORD
            CASE boolean OF
                true:
                    (selr_selectbuffer   : tgg00_SelectBuffer;
                    selr_resf_id        : tgg00_FileId;
                    selr_inv_id         : tgg00_FileId;
                    selr_distinct_id    : tgg00_FileId;
                    selr_intersect_id   : tgg00_FileId;
                    selr_tree_pos       : tgg00_FilePos;
                    selr_id_outer_join  : tgg00_FileId;
                    selr_oj_tree_pos    : tgg00_FilePos;
                    selr_countresult    : tsp_int4;
                    selr_act_cntresult  : tsp_int4;
                    selr_resrec_maxlen  : tsp_int4;
                    selr_maxresult      : tsp_int4;
                    selr_group_count    : tsp_int4;
                    selr_union_icnt     : tsp_int4;
                    selr_cnt_outer_join : tsp_int4;
                    selr_disrootarr     : tkb7_distinct_roots;
                    selr_r_currpos      : tsp_int2;
                    selr_r_endpos       : tsp_int2;
                    selr_l_currpos      : tsp_int2;
                    selr_l_endpos       : tsp_int2;
                    selr_lmaxpos        : tsp_int2;
                    selr_first_jlen     : tsp_int2;
                    selr_l_defbyte_pos  : tsp_int2;
                    selr_keyl           : tsp_int2;
                    selr_startkey       : tgg_lkey;
                    selr_stopkey        : tgg_lkey;
                    selr_invkey         : tgg_lkey;
                    selr_recl           : tsp_int2;
                    selr_distinct       : tgg_distinct;
                    selr_distinct_bytes : boolean;
                    selr_union          : boolean;
                    selr_one_result     : boolean;
                    selr_subquery       : boolean;
                    selr_intern_dist    : boolean;
                    selr_is_nokey       : boolean;
                    selr_count_all      : boolean;
                    selr_count_bd       : boolean;
                    selr_dupl           : tsp_c1;
                    selr_use_rowno      : boolean;
                    selr_fulfilled      : boolean;
                    selr_append_all     : boolean;
                    selr_union_select   : boolean;
                    selr_isunion        : boolean;
                    selr_isexcept       : boolean;
                    selr_isintersect    : boolean;
                    selr_isall          : boolean;
                    selr_key_cnt_offs   : tsp_int4;
                    selr_no_warn8_sort  : boolean;
                    selr_oracle_selinto : boolean;
                    selr_l_null_val_fnd : boolean;
                    selr_r_null_val_fnd : boolean;
                    selr_join_with_func : boolean;
                    selr_all_recursive  : boolean;
                    selr_filler         : tsp_int4);
                false:
                    (selr_ptrallignment : tsp_moveobj_ptr);
                END;
            (*ENDCASE*) 
 
 
      tkb7_oj_info_type = RECORD
            oj_ok_keys_id  : tgg00_FileId;
            is_outer_join  : boolean;
      END;
 
 
      tkb7_one_new_pos = RECORD
            onfrom  : tsp_int2;
            onto    : tsp_int2;
            onlen   : tsp_int2;
            onouter : boolean;
            on_fill : tsp00_Uint1;
      END;
 
 
      tkb7_new_positions = RECORD
            posarr  : ARRAY [ 1..ckb7_maxnewpos ] OF tkb7_one_new_pos;
            lposcnt : tsp_int2;
            rposcnt : tsp_int2;
      END;
 
 
      tkb7_lr_rec_counter = RECORD
            l_rec_id  : tsp_int4;
            r_rec_id  : tsp_int4;
      END;
 
      tkb7_outer_join_type = (no_outer_join,
            left_outer_join,
            right_outer_join);
 
      tkb7_get_param = RECORD
            gi_n_pos_s       : tkb7_new_positions;
            gi_linkrec       : tgg07_KbJoinRec;
            gi_njrec         : tgg07_NextJoins;
            gi_minfo         : tgg07_MInfos;
            gi_lr_rec_id     : tkb7_lr_rec_counter;
            gi_mto_outer_tab : tkb7_outer_join_type;
      END;
 
      tkb7_ora_number_fmt_elem = (
            onf_no_correct_format,
            onf_nine,
            onf_zero,
            onf_sign_at_this_position,
            onf_sign_at_end,
            onf_sign_brackets,
            onf_currency_dollar,
            onf_currency_iso,
            onf_currency_local,
            onf_blank,
            onf_decimal_implicit,
            onf_decimal_point,
            onf_decimal_dot,
            onf_seperator,
            onf_seperator_comma,
            onf_exponent,
            onf_roman_numeral_lower,
            onf_roman_numeral_upper);
 
      tkb7_rec_buf = RECORD
            CASE boolean OF
                true:
                    (buf   : tsp_buf);
                false:
                    (rec_head : tgg00_HeaderRec;
                    info      : tgg_mess_info_buf);
                END;
 
.CM *-END-* code ----------------------------------------
.SP 2 
***********************************************************
*-PRETTY-*  statements    :          0
*-PRETTY-*  lines of code :        142        PRETTYX 3.10 
*-PRETTY-*  lines in file :        244         1997-12-10 
.PA 
