![]() |
/**************************************************************************
This program create a report from the Oracle database table by
using proc compiler
It is checked in DRS600 Sparc V release 4.0
It is fast compare with the SQL report writer.
Go thru the codes and implemene in your syste.
Note: You may need to some changes in this code when you
migrate it to the other cersions of unix and Oracle.
It checked oly in Oracle 7.1
**************************************************************************/
/* -------------- Programmer: G.Pradeep -------------
Special Acknowledgment & Thanks to Mr Pradeep Kumar.M, DBA, MIl Controls Ltd.
Creation Date :- 14/2/2000
Objective :- To print product card for the valve
Tables used
mrpcvjobhdr, mrpcvjobdtl, copcustmast, mil_fixed_code,
mrppctccode, copordhdr, coporditm, stkmast, copsopin,
copordrem , mrppaintingstddtl
Last date of modification : 23/06/2000
Modification done : Changed the format of the printing of Materials
*/
#include <stdio.h>
#include <ctype.h>
#include <string.h>
#include <stdlib.h>
#define spc " "
#define sline "--------------------------------------------------"
#define bline "------------------------------------------------------------------------------------------------------------------"
#define nline "\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n"
EXEC SQL INCLUDE SQLCA;
EXEC SQL BEGIN DECLARE SECTION;
/* ------ Variable Declarations starting ---------*/
varchar uid[20] , pswd[20] ;
/*To store user id and password to connect to oracle */
varchar job_no[12] , job_sl_no[3] , cust_name[50] ,
spec_date[10] , tag_no[20] , model_no[40] ,
valve_size[40] , body_rating[40] , end_conn[40] ,
charstic[40] , stroke[40] , bonnet_type[40] ,
act_size[40] , spring_range[40] , af_pos[10] ,
cust_insp_ind[3] , body[60] , bonnet[60] ,
plug[60] , pilot[60] , seat[60] ,
plugstem[60] , packing[60] , brush[60] ,
cage[60] , body_sl_no[10] , body_heat_no[10] ,
body_rt_no[10] , body_ut_no[10] , bonnet_sl_no[10] ,
bonnet_heat_no[10] , bonnet_rt_no[10] , bonnet_ut_no[10] ,
acc_desc[20][70] , test_medium[6] , ibr_req_ind[3] ,
ibr_cert_no[12] , flow_direction[5] , tubing[20] ,
liner[60] , spacer[60] , drng_ind[15] ,
air_to_ind[10] , sl_test_uom[15] , ht_uom[15] ,