#include "hgupstorematlist.h" #define SQLCA_STORAGE_CLASS extern #define ORACA_STORAGE_CLASS extern #include #include #define MAXCOMP 5 // ************************************************************************ // ---------------------- storeObj ----------------------------------------- // ************************************************************************ long HGupStoreMatlist::storeObj() { // stores a new object in MATLIST if (materialIndex <= 0) { cerr << "error in HGupStoreMatlist::storeObj: materialIndex = " << materialIndex << endl; return -1; }; EXEC SQL BEGIN DECLARE SECTION; int Material_Index[MAXCOMP]; int Comp_Index[MAXCOMP]; float Matlist_Weight[MAXCOMP]; int RowsToInsert; EXEC SQL END DECLARE SECTION; nComp=compIndex.length(); RowsToInsert=nComp; if (nComp>MAXCOMP) { cerr << "number of components = " << nComp << " too large" << endl; return -1; } for (int i=0;i