コード例 #1
0
ファイル: SystemBatchManager.cs プロジェクト: minikie/test
        public static void updateBatchJobID_end(DateTime refDate, clsHDAT_BATCHJOB_RESULT_TB.BATCH_JOB_ID_Type jobType)
        {
            // basedata 딴데서 만듬.

            clsHDAT_BATCHJOB_RESULT_TB clstb = new clsHDAT_BATCHJOB_RESULT_TB();

            clstb.BATCH_JOB_ID = (int)jobType;
            clstb.CALC_DT = refDate.ToString("yyyyMMdd");

            if (clstb.SelectOwn() == 0)
                { throw new Exception(" not yet started : " + clstb.CALC_DT + " " + clstb.BATCH_JOB_ID); }

            clstb.CALC_DT = refDate.ToString("yyyyMMdd");
            clstb.BATCH_JOB_ID = (int)jobType;
            //clstb.START_TIME = startTime.ToString("HH:mm:ss");
            clstb.END_TIME = DateTime.Now.ToString("HH:mm:ss");
            clstb.DURATION_TIME = "999999";// (DateTime.Now - ConvertingTool.ToDateTime(clstb.START_TIME)).ToString("HH:mm:ss");
            clstb.STATUS = (int)clsHDAT_BATCHJOB_RESULT_TB.STATUS_Type.CALCULATED;

            if (clstb.UpdateBatch() == 0)
                { throw new Exception("update fail : " + clstb.CALC_DT + " " + clstb.BATCH_JOB_ID); }

        }
コード例 #2
0
ファイル: SystemBatchManager.cs プロジェクト: minikie/test
        public static void updateBatchJobID_error(DateTime refDate, clsHDAT_BATCHJOB_RESULT_TB.BATCH_JOB_ID_Type jobType)
        {
            // basedata 딴데서 만듬.

            clsHDAT_BATCHJOB_RESULT_TB clstb = new clsHDAT_BATCHJOB_RESULT_TB();

            clstb.CALC_DT = refDate.ToString("yyyyMMdd");
            clstb.BATCH_JOB_ID = (int)jobType;
            clstb.STATUS = (int)clsHDAT_BATCHJOB_RESULT_TB.STATUS_Type.ERROR;

            if (clstb.UpdateBatch() == 0)
                { throw new Exception("update fail : " + clstb.CALC_DT + " " + clstb.BATCH_JOB_ID); }

        }
コード例 #3
0
ファイル: SystemBatchManager.cs プロジェクト: minikie/test
        // db update

        #region batch_db_update
        
        public static void updateBatchJobID_start(DateTime refDate, clsHDAT_BATCHJOB_RESULT_TB.BATCH_JOB_ID_Type jobType) 
        {
            // basedata 딴데서 만듬.

            clsHDAT_BATCHJOB_RESULT_TB clstb = new clsHDAT_BATCHJOB_RESULT_TB();

            clstb.CALC_DT = refDate.ToString("yyyyMMdd");
            clstb.BATCH_JOB_ID = (int)jobType;
            clstb.START_TIME = DateTime.Now.ToString("HH:mm:ss");
            clstb.END_TIME = "999999";
            clstb.DURATION_TIME = "999999";
            clstb.STATUS = (int)clsHDAT_BATCHJOB_RESULT_TB.STATUS_Type.CALCULATING;

            if (clstb.UpdateBatch() == 0)
            {
                clstb.Insert();
            }
            else
            {
                //throw new Exception("update fail : " + clstb.CALC_DT + " " + clstb.BATCH_JOB_ID);
            }

        }