| | | | |
| #include "../schema.mac" |
| #include "../bop.mac" |
| |
| TABLE Prob_Category |
| { |
| | sym | | STRING 75; |
| | zcode | | STRING 12; |
| } |
| |
| TABLE Trouble_Code |
| { |
| | sym | | STRING 75; |
| | zcode | | STRING 12; |
| } |
| |
| TABLE zManufacturer SMALL LOW_VOLATILE |
| { |
| | id | | INTEGER UNIQUE NOT_NULL KEY; |
| | code | | STRING 12; |
| | del | | INTEGER NOT_NULL; |
| | sym | | STRING 60 UNIQUE NOT_NULL S_KEY; |
| | loc_id | | INTEGER REF Location; |
| | desc | | STRING 40; |
| } |
| p1 zManufacturer -> CURR_PROV zmanufacturer{desc -> nx_desc;} |
| |
| TABLE General_Resource_Class |
| { |
| | ztech | | INTEGER REF zTechnology; |
| | zmfr_id | | INTEGER REF zManufacturer; |
| | zpart_no | | STRING 20; |
| } |
| |
| TABLE Network_Resource |
| { |
| | zcode | | STRING 20; |
| | zclsftn | | INTEGER REF zClassification; |
| | ziss_date_cso | | DATE_TIME; |
| | zret_date_com | | DATE_TIME; |
| } |
| |
| TABLE NR_Comment |
| { |
| | zdel | | INTEGER uniq; | // 0=present,1=gone |
| | zinst_date | | DATE_TIME; |
| | zfail_date | | DATE_TIME; |
| | zconsignee | | INTEGER REF Contact; |
| | zrp_by_id | | INTEGER REF Contact; |
| | znew_serial_no | | STRING 30; |
| | zreason | | STRING 100; | | // text description |
| } |
| |
| TABLE Call_Req |
| { |
| | zinst_id | | INTEGER REF zInstallation_Demonstration; |
| | zct_type_id | | INTEGER REF Contact_Type; |
| |
| | zcaller | | STRING 30; |
| | zold_srl_num | | STRING 30; |
| |
| | zconv_exp | | STRING 10; |
| | ztour_exp | | STRING 10; |
| | zpurc_exp | | STRING 10; |
| | zothr_exp | | STRING 10; |
| |
| | zstart_date | | DATE_TIME; |
| | zarriv_date | | DATE_TIME; |
| | zdepart_date | | DATE_TIME; |
| | zreturn_date | | DATE_TIME; |
| |
| | zcall_report_date | | DATE_TIME; |
| | zcall_end_date | | DATE_TIME; |
| | ztravel_from | | ENT_NAME; |
| | ztravel_to | | ENT_NAME; |
| | zdown_time | | DURATION; |
| | zacc_down_time | | DURATION; |
| | zreason | | STRING 100; |
| | zstatus | | INTEGER REF zStatus; |
| | ztravel_time | | DURATION; |
| | zresponse_time | | DURATION; |
| | zce_remarks | | STRING 80; |
| | zmanager_remarks | | STRING 80; |
| | zcst_remarks | | STRING 80; |
| | zsolve_mode_id | | INTEGER REF zSolve_Mode; |
| | zregistered | | INTEGER REF Boolean_Table; |
| | zaction | | STRING 80; |
| | zproduct_code | | INTEGER REF Network_Resource; |
| | zpayment_mode_id | | INTEGER REF zPayment_Mode; |
| | zcheque_number | | STRING 30; |
| | zcheque_date | | DATE_TIME; |
| | zamt | | STRING 30; |
| | zamt_for | | STRING 30; |
| |
| | znum_rem | | INTEGER; |
| | zrem1_date | | DATE_TIME; |
| | zrem2_date | | DATE_TIME; |
| | zrem3_date | | DATE_TIME; |
| | zrem_desc | | STRING 80; |
| |
| | zrepair_code_id | | INTEGER REF zRepair_Code; |
| | zspare_repl_date | | DATE_TIME; |
| | zccr_no | | STRING 30; |
| } |
| |
| TABLE Location |
| { |
| | l_name | | STRING 75; |
| | zrcity_id | | INTEGER REF zRCity; |
| | zstate_id | | INTEGER REF zState; |
| } |
| |
| TABLE Contact |
| { |
| // | | Commmon fields |
| | c_last_name | | STRING 75; |
| | zcontact | | ENT_NAME; |
| | zdesg_id | | INTEGER REF zDesignation; |
| |
| // | | Common for Customer and Employee |
| | zarea_id | | INTEGER REF zArea_Office; |
| |
| // | | Customer |
| | zlob | | INTEGER REF zLine_Of_Business; |
| | ztech | | INTEGER REF zTechnology; |
| | |
| // | | Consignee |
| | zvsat_id | | SYMBOL; |
| | zcity_id | | INTEGER REF zCity; |
| | zinst_id | | INTEGER REF zInstallation_Demonstration; |
| | zparent_cst | | INTEGER REF Contact; |
| |
| // | | Employee |
| | zjoin_date | | DATE_TIME; |
| | zpost_date | | DATE_TIME; |
| | zhier_struc | | ENT_NAME; |
| | zskill_id | | INTEGER REF zSkill; |
| | zqual | | INTEGER REF zQualifications; |
| | zprev_exp | | STRING 20; |
| | zcurr_exp | | STRING 20; |
| } |
| |
| TABLE zClassification MEDIUM READ_ONLY |
| { |
| | id | | INTEGER uniq KEY; | // id | |
| | del | | INTEGER uniq; | // 0=present,1=gone |
| | sym | | HIER_SYM | | uniq S_KEY; |
| | desc | | LONG_DESC; | | // text description |
| } |
| p1 zClassification -> CURR_PROV zclassification{desc -> nx_desc;} |
| |
| TABLE zQualifications MEDIUM READ_ONLY |
| { |
| | id | | INTEGER uniq KEY; | // id | |
| | del | | INTEGER uniq; | // 0=present,1=gone |
| | sym | | HIER_SYM | | uniq S_KEY; |
| | desc | | LONG_DESC; | | // text description |
| } |
| p1 zQualifications -> CURR_PROV zqualifications{desc -> nx_desc;} |
| |
| TABLE zSkill SMALL READ_ONLY |
| { |
| | id | | INTEGER uniq KEY; | // id | |
| | enum | | INTEGER NOT_NULL ; |
| | del | | INTEGER uniq; | // 0=present,1=gone |
| | sym | | ENT_NAME uniq S_KEY; |
| | desc | | LONG_DESC; | | // text description |
| } |
| p1 zSkill -> CURR_PROV zskill{desc -> nx_desc;} |
| |
| TABLE zLine_Of_Business MEDIUM READ_ONLY |
| { |
| | id | | INTEGER uniq KEY; | // id | |
| | del | | INTEGER uniq; | // 0=present,1=gone |
| | sym | | HIER_SYM | | uniq S_KEY; |
| | desc | | LONG_DESC; | | // text description |
| } |
| p1 zLine_Of_Business -> CURR_PROV zlob{desc -> nx_desc;} |
| |
| TABLE zTechnology MEDIUM READ_ONLY |
| { |
| | id | | INTEGER uniq KEY; | // id | |
| | del | | INTEGER uniq; | // 0=present,1=gone |
| | sym | | HIER_SYM uniq S_KEY; |
| | desc | | LONG_DESC; | | // text description |
| } |
| p1 zTechnology -> CURR_PROV ztech{desc -> nx_desc;} |
| |
| TABLE zStatus MEDIUM READ_ONLY |
| { |
| | id | | INTEGER uniq KEY; | // id | |
| | del | | INTEGER uniq; | // 0=present,1=gone |
| | sym | | HIER_SYM uniq S_KEY; |
| | desc | | STRING 100; | | // text description |
| } |
| p1 zStatus -> CURR_PROV zstatus{desc -> nx_desc;} |
| |
| TABLE zDesignation MEDIUM READ_ONLY |
| { |
| | id | | INTEGER uniq KEY; | // id | |
| | del | | INTEGER uniq; | // 0=present,1=gone |
| | sym | | HIER_SYM | | uniq S_KEY; |
| | desc | | LONG_DESC; | | // text description |
| } |
| p1 zDesignation -> CURR_PROV zdesignation{desc -> nx_desc;} |
| |
| TABLE zCategory MEDIUM READ_ONLY |
| { |
| | id | | INTEGER uniq KEY; | // id | |
| | del | | INTEGER uniq; | // 0=present,1=gone |
| | sym | | HIER_SYM | | uniq S_KEY; |
| | desc | | LONG_DESC; | | // text description |
| } |
| p1 zCategory -> CURR_PROV zcat{desc -> nx_desc;} |
| |
| TABLE zStation MEDIUM READ_ONLY |
| { |
| | id | | INTEGER uniq KEY; | // id | |
| | del | | INTEGER uniq; | // 0=present,1=gone |
| | sym | | HIER_SYM | | uniq S_KEY; |
| | desc | | LONG_DESC; | | // text description |
| } |
| p1 zStation -> CURR_PROV zstation{desc -> nx_desc;} |
| |
| TABLE zRepair_Code MEDIUM READ_ONLY |
| { |
| | id | | INTEGER uniq KEY; | // id | |
| | del | | INTEGER uniq; | // 0=present,1=gone |
| | sym | | HIER_SYM | | uniq S_KEY; |
| | desc | | LONG_DESC; | | // text description |
| } |
| p1 zRepair_Code -> CURR_PROV zrepair_code{desc -> nx_desc;} |
| |
| TABLE zSolve_Mode MEDIUM READ_ONLY |
| { |
| | id | | INTEGER uniq KEY; | // id | |
| | del | | INTEGER uniq; | // 0=present,1=gone |
| | sym | | HIER_SYM | | uniq S_KEY; |
| | desc | | LONG_DESC; | | // text description |
| } |
| p1 zSolve_Mode -> CURR_PROV zsolve_mode{desc -> nx_desc;} |
| |
| TABLE zPayment_Mode MEDIUM READ_ONLY |
| { |
| | id | | INTEGER uniq KEY; | // id | |
| | del | | INTEGER uniq; | // 0=present,1=gone |
| | sym | | HIER_SYM | | uniq S_KEY; |
| | desc | | LONG_DESC; | | // text description |
| } |
| p1 zPayment_Mode -> CURR_PROV zpayment_mode{desc -> nx_desc;} |
| |
| TABLE zRCity MEDIUM READ_ONLY |
| { |
| | id | | INTEGER uniq KEY; | // id | |
| | del | | INTEGER uniq; | // 0=present,1=gone |
| | sym | | ENT_NAME uniq S_KEY; |
| | state | | INTEGER REF zState; |
| | desc | | LONG_DESC; | | // text description |
| } |
| p1 zRCity -> CURR_PROV zrcity{desc -> nx_desc;} |
| |
| TABLE zRegion MEDIUM READ_ONLY |
| { |
| | id | | INTEGER uniq KEY; | // id | |
| | del | | INTEGER uniq; | // 0=present,1=gone |
| | sym | | ENT_NAME uniq S_KEY; |
| | desc | | LONG_DESC; | | // text description |
| } |
| p1 zRegion -> CURR_PROV zregion{desc -> nx_desc;} |
| |
| TABLE zCity MEDIUM READ_ONLY |
| { |
| | id | | INTEGER uniq KEY; | // id | |
| | del | | INTEGER uniq; | // 0=present,1=gone |
| | code | | SYMBOL uniq S_KEY; |
| | sym | | ENT_NAME; |
| | location | | INTEGER REF Location; |
| | area_id | | INTEGER REF zArea_Office; |
| | station | | INTEGER REF zStation; |
| | desc | | LONG_DESC; | | // text description |
| } |
| p1 zCity -> CURR_PROV zcity{desc -> nx_desc;} |
| |
| TABLE zRegion_Office MEDIUM READ_ONLY |
| { |
| | id | | INTEGER uniq KEY; | // id | |
| | del | | INTEGER uniq; | // 0=present,1=gone |
| | code | | SYMBOL uniq S_KEY; |
| | sym | | ENT_NAME; |
| | location | | INTEGER REF Location; |
| | contact_name | | ENT_NAME; |
| | designation | | INTEGER REF zDesignation; |
| | office_name | | INTEGER REF zRCity; |
| | region | | INTEGER REF zRegion; |
| | desc | | LONG_DESC; | | // text description |
| } |
| p1 zRegion_Office -> CURR_PROV zregion_office{desc -> nx_desc;} |
| |
| TABLE zArea_Office MEDIUM READ_ONLY |
| { |
| | id | | INTEGER uniq KEY; | // id | |
| | del | | INTEGER uniq; | // 0=present,1=gone |
| | code | | SYMBOL uniq S_KEY; |
| | sym | | ENT_NAME; |
| | location | | INTEGER REF Location; |
| | ro_id | | INTEGER REF zRegion_Office; |
| | desc | | LONG_DESC; | | // text description |
| } |
| p1 zArea_Office -> CURR_PROV zarea_office{desc -> nx_desc;} |
| |
| TABLE zState MEDIUM READ_ONLY |
| { |
| | id | | INTEGER uniq KEY; | // id | |
| | del | | INTEGER uniq; | // 0=present,1=gone |
| | sym | | HIER_SYM uniq S_KEY; |
| | desc | | STRING 100; | | // text description |
| } |
| p1 zState -> CURR_PROV zstate{desc -> nx_desc;} |
| |
| TABLE zMonth SMALL READ_ONLY |
| { |
| | id | | INTEGER uniq KEY; | // id | |
| | enum | | INTEGER NOT_NULL ; |
| | del | | INTEGER uniq; | // 0=present,1=gone |
| | sym | | HIER_SYM | | uniq S_KEY; |
| | desc | | STRING 100; | | // text description |
| } |
| p1 zMonth -> CURR_PROV zmonth{desc -> nx_desc;} |
| |
| TABLE zInstallation_Demonstration MEDIUM READ_ONLY |
| { |
| | id | | INTEGER uniq KEY; | // id | |
| | del | | INTEGER uniq; | // 0=present,1=gone |
| | sym | | HIER_SYM uniq S_KEY; |
| | consignee | | INTEGER REF Contact; |
| | log_agent | | INTEGER nn REF Contact; |
| | category | | INTEGER REF zCategory; |
| | exp_date | | DATE_TIME; |
| | readiness | | INTEGER REF Boolean_Table; |
| | re_site_srvy_date | | DATE_TIME; |
| | why_not_ready | | STRING 100; | | // text description |
| | tnt_srvy_date | | DATE_TIME; |
| | act_srvy_date | | DATE_TIME; |
| | tnt_inst_date | | DATE_TIME; |
| | act_inst_date | | DATE_TIME; |
| | tnt_sint_date | | DATE_TIME; |
| | act_sint_date | | DATE_TIME; |
| | tnt_actv_date | | DATE_TIME; |
| | act_actv_date | | DATE_TIME; |
| | demo | | INTEGER; |
| | sys_intg_req | | INTEGER; |
| | ttl_tm_prvd | | INTEGER; |
| | amc_amt | | INTEGER; |
| | desc | | STRING 100; | | // text description |
| } |
| p1 zInstallation_Demonstration -> CURR_PROV zinst_demo{desc -> nx_desc;} |
| |
| TABLE zEngineer_Attendance MEDIUM READ_ONLY |
| { |
| | id | | INTEGER uniq KEY; | // id | |
| | del | | INTEGER uniq; | // 0=present,1=gone |
| | log_agent | | INTEGER nn REF Contact; |
| | engineer | | INTEGER REF Contact; |
| | month | | DATE_TIME; |
| | wrkng_days | | INTEGER; |
| | in_prsnt_days | | INTEGER nn; |
| | out_prsnt_days | | INTEGER nn; |
| | desc | | STRING 200; | | // text description |
| } |
| p1 zEngineer_Attendance -> CURR_PROV zeng_att{desc -> nx_desc;} |