/** * Lay gia tri dua vao define cua App * * @param _app * @param _queryser */ public void queryToAppDefine(AppCommon _app, QueryServer _queryser) { Date date; DateFormat dateFormat; // Bat buoc this.set_fileurl(_app.get_scriptUrl() + this.get_fileurl()); // Lay duong dan he thong cau hinh this.readScript(); // doc file this.set_define(_app.get_define()); this .setquery(); // Set lai cau script lay - Lay define cua Query (neu cau set lai define cua // Appcomon) // this.logQuery(); dateFormat = new SimpleDateFormat("yyyyMMdd_HHmmss"); date = new Date(); this.set_startDate(dateFormat.format(date)); _app.set_define(CommandQuery.queryGetVar(_queryser.get_conn(), this.get_exquery())); date = new Date(); this.set_endDate(dateFormat.format(date)); logger.info( "S[" + this.get_startDate() + "], E[" + this.get_endDate() + "]. queryToAppDefine successful with name: " + this.get_querynm()); }