Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2024-04-06 12:23:05

0001 #include "OnlineDB/EcalCondDB/interface/LMFCorrVers.h"
0002 
0003 using namespace std;
0004 using namespace oracle::occi;
0005 
0006 LMFCorrVers::LMFCorrVers() : LMFPrimVers() {
0007   setClassName("LMFCorrVers");
0008   setString("description", "");
0009 }
0010 
0011 LMFCorrVers::LMFCorrVers(EcalDBConnection *c) : LMFPrimVers(c) {
0012   setClassName("LMFCorrVers");
0013   setString("description", "");
0014 }
0015 
0016 LMFCorrVers::LMFCorrVers(oracle::occi::Environment *env, oracle::occi::Connection *conn) : LMFPrimVers(env, conn) {
0017   setClassName("LMFCorrVers");
0018   setString("description", "");
0019 }
0020 
0021 LMFCorrVers::~LMFCorrVers() {}
0022 
0023 std::string LMFCorrVers::fetchIdSql(Statement *stmt) { return ""; }
0024 
0025 std::string LMFCorrVers::setByIDSql(Statement *stmt, int id) {
0026   std::string sql =
0027       "SELECT DESCR FROM "
0028       "CMS_ECAL_LASER_COND.LMF_CORR_VERS "
0029       "WHERE VERS = :1";
0030   stmt->setSQL(sql);
0031   stmt->setInt(1, id);
0032   return sql;
0033 }
0034 
0035 void LMFCorrVers::getParameters(ResultSet *rset) { setString("description", rset->getString(1)); }
0036 
0037 LMFUnique *LMFCorrVers::createObject() const {
0038   LMFCorrVers *t = new LMFCorrVers;
0039   t->setConnection(m_env, m_conn);
0040   return t;
0041 }
0042 
0043 std::string LMFCorrVers::fetchAllSql(Statement *stmt) const {
0044   std::string sql = "SELECT VERS FROM CMS_ECAL_LASER_COND.LMF_CORR_VERS";
0045   stmt->setSQL(sql);
0046   return sql;
0047 }