Commit e849c126 authored by sgadve's avatar sgadve

migrating the employeetransferSql form NVO to JB

git-svn-id: http://15.206.35.175/svn/proteus/business-java/trunk@207295 ce508802-f39f-4f6c-b175-0d175dae99d5
parent 331a1632
Insert into TRANSETUP (TRAN_WINDOW,SAVE_FLAG,VAL_FLAG,KEY_FLAG,KEY_STRING,UDF_1,UDF_2,UDF_3,UDF_4,UDF_5,REPEATE_ADD,CHG_DATE,CHG_USER,CHG_TERM,EDI_OPTION,SITE_ACC_COL,CONFIRM_COL,CONFIRM_VAL,REPEAT_ADD_DET,REPEATADDDET,LOAD_MODE,AUTO_CONFIRM,LEDG_POST_CONF,CHG_DATE_ON_CONF,TRAN_ID_COL,MAIL_OPTION,CONFIRM_MODE,GARBAGE_OPT,VAL_FLAG_EDI,VERIFY_PASSWORD,CUST_ACC_COL,SALES_PERS_ACC_COL,SUPP_ACC_COL,ITEM_SER_ACC_CODE,EMP_ACC_COL,ITEM_SER_ACC_COL,WORKFLOW_OPT,TABLE_NAME,APPLICATION,TABLE_DESC,TRAN_DATE_COL,TRAN_ID__FROM,TRAN_ID__TO,TABLE_NAME_DET1,TABLE_NAME_DET2,TABLE_NAME_DET3,MULTITIRE_OPT,REF_SER,VIEW_MODE,TAX_FORMS,SIGN_STATUS,USER_TRAN_WINDOW,CUSTOM_PREVIEW_OBJ,IGNOREERRLIST_ONLOAD,CHILDDATA_ARGOPT,EDIT_TMPLT,WRKFLW_INIT,EDITTAX,FORMAL_ARGS,AUDIT_TRAIL_OPT,EDIT_OPT,CACHE_OPT,OPTIMIZE_MODE,EDIT_EXPR,RATE_COL,QTY_COL,EDIT_EXPR_INP,RCP_CACHE_STATUS,PRINT_CONTROL,TRANSFER_MODE,PROFILE_ID__RES,TRAN_COMPL_MSG,PERIOD_OPTION,WRKFLW_PRIORITY,EXEC_TYPE,DISP_META_DATA,ALLOW_ATTACH,START_FORM,ISATTACHMENT,HEADER_FORM_NO,CONFIRM_DATE_COL,CONFIRM_BY_COL,MSG_ONSAVE,WF_STATUS,RESTART_FORM,CMS_PATH,BROW_DATA_DEF,DEF_VIEW,VIEW_OPTS,ISGWTINITIATED,DEFAULT_DATA_ROW,IN_WF_VAL,IN_WF_COL,CANCEL_VAL,CANCEL_COL,THUMB_ALT_COL,THUMB_IMAGE_COL,THUMB_OBJ,ATTACH_COUNT_MIN,FUNCTION_TYPE,COMPL_ACTION,DEFAULT_EDITOR,MSG_NO,OBJ_TYPE,STATUS_COL,ENABLE_EDITOR,OFFLINE_OPT,CLOSE_COL,CLOSE_VAL) values ('w_emptransfersql','2','2','A','seq10',null,null,null,null,null,'Y',to_date('08-11-13','DD-MM-RR'),'Nikhil ','payroll ','0','SITE_CODE',null,null,'Y',null,null,'N','N',null,'pay_table',null,null,null,null,null,null,null,null,null,null,null,'0',null,null,null,null,null,null,null,null,null,null,'PAYTBL','F',null,null,null,null,null,null,null,null,null,null,'0',null,null,null,null,null,null,null,null,null,null,null,null,'M',null,null,null,null,null,null,null,null,null,null,null,null,null,'Y',null,null,null,null,null,null,null,null,null,null,null,null,null,null,'compact',null,null,null,null,null,null,null);
Insert into itm2menu (APPLICATION,LEVEL_1,LEVEL_2,LEVEL_3,LEVEL_4,LEVEL_5,WIN_NAME,DESCR,COMMENTS,MENU_PATH,ICON_PATH,CLOSE_ICON,OPEN_ICON,OBJ_TYPE,CHG_DATE,CHG_TERM,CHG_USER,MOB_DEPLOY,DEFAULT_STATE,DEF_ACTION) values ('ADM',2,1,17,0,0,'w_emptransfersql','X. Employee Transfer SQLs','SQLs for transfering data for employee transfered','ADM.2.1.17.0.0',null,null,null,null,null,null,null,null,null,null);
Insert into OBJ_FORMS (WIN_NAME,TITLE,OBJ_BROW_NAME,OBJ_EDIT_NAME,CROSS_UPDATE_EXPR,EXPR_FLD_INFO,TARGET_FLD_INFO,EXPR_COMMENT,FORM_NO,SCR_FLAG,AUTO_ACCEPT_SCAN,SCAN_FLAG,SCAN_METADATA,PROPERTY_INFO,SCAN_DELIMITER,COLUMN_ON_SAVE,AFTER_SAVE,EXT_SETUP,EXT_METADATA,EXT_COM,AUTO_ACCEPT_WEIGHDATA,FORM_TYPE,DISP_METADATA,PARENT_KEY_COL,QTY_COL,RATE_COL,ASSISTED_MODE,STORAGE_KEY_METADATA,SELECTION_MODE,DEFAULT_VIEW,AUTO_ADDON_ENTRY,DUPLICATE_ADD,DEFAULT_ROW_CNT,FREEZE_COL_POS,IS_MANDATORY,TRAN_ID_COL,SELECTION_OPT,KEY_INFO,THUMB_OBJ,THUMB_IMAGE_COL,THUMB_ALT_COL,FORM_NAME,FORM_ICON,FORM_VIEW_OPTS,X_COLUMN,Y_COLUMN,ACTION_ARG) values ('w_emptransfersql','empty transfer sql','emptransfersql',null,null,null,null,null,'1','F',null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null);
insert into obj_itemchange (obj_name,field_name,form_no,mandatory) values ('emptransfersql','table_name','1','Y');
insert into obj_itemchange (obj_name,field_name,form_no,mandatory) values ('emptransfersql','itm_default','1','Y');
update transetup set tran_id_col='' where tran_window='w_emptransfersql';
Insert into SYSTEM_EVENTS (OBJ_NAME,EVENT_CODE,EVENT_CONTEXT,SERVICE_CODE,METHOD_RULE,OVERWRITE_CORE,CHG_DATE,CHG_USER,CHG_TERM,RESULT_HANDLE,COMP_TYPE,COMP_NAME,COMM_FORMAT) values ('emptransfersql','pre_validate','1','prv_default_ejb',null,'0',sysdate,'BASE','BASE','2','JB','ibase.webitm.ejb.adm.EmpTransferSqlIc',null);
Insert into SYSTEM_EVENTS (OBJ_NAME,EVENT_CODE,EVENT_CONTEXT,SERVICE_CODE,METHOD_RULE,OVERWRITE_CORE,CHG_DATE,CHG_USER,CHG_TERM,RESULT_HANDLE,COMP_TYPE,COMP_NAME,COMM_FORMAT) values ('emptransfersql','post_item_change','1','poic_default_ejb',null,'0',sysdate,'BASE','BASE','2','JB','ibase.webitm.ejb.adm.EmpTransferSqlIc',null);
Insert into POPHELP (FIELD_NAME,MOD_NAME,SQL_STR,DW_OBJECT,MSG_TITLE,WIDTH,HEIGHT,CHG_DATE,CHG_USER,CHG_TERM,DIST_OPT,FILTER_STRING,SQL_INPUT,DEFAULT_COL,POP_ALIGN,QUERY_MODE,PAGE_CONTEXT,POPHELP_COLS,POPHELP_SOURCE,MULTI_OPT,HELP_OPTION,POPUP_XSL_NAME,AUTO_FILL_LEN,THUMB_OBJ,THUMB_IMAGE_COL,THUMB_ALT_COL,AUTO_MIN_LENGTH,OBJ_NAME__DS,DATA_MODEL_NAME,VALIDATE_DATA,ITEM_CHANGE,MSG_NO,FILTER_EXPR,LAYOUT) values ('TABLE_NAME','W_EMPTRANSFERSQL','select TABLE_NAME from transetup where TABLE_NAME is not null',null,'Table Name',null,null,to_date('13-09-18','DD-MM-RR'),null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null);
Insert into MESSAGES (MSG_NO,MSG_STR,MSG_DESCR,MSG_TYPE,MSG_OPT,MSG_TIME,ALARM,ERR_SOURCE,CHG_DATE,CHG_USER,CHG_TERM,OVERRIDE_INPUT,MAIL_OPTION) values ('VTTABNAME','Table name already exists','Invalid Table name,table name already exists','E','Y',null,null,null,sysdate,'TSD','TSD',null,null);
Insert into MESSAGES (MSG_NO,MSG_STR,MSG_DESCR,MSG_TYPE,MSG_OPT,MSG_TIME,ALARM,ERR_SOURCE,CHG_DATE,CHG_USER,CHG_TERM,OVERRIDE_INPUT,MAIL_OPTION) values ('VTSQLSELE','Please check the SQL','Incorrect SQL please check the SQL','E','Y',null,null,null,sysdate,'TSD','TSD',null,null);
Insert into MESSAGES (MSG_NO,MSG_STR,MSG_DESCR,MSG_TYPE,MSG_OPT,MSG_TIME,ALARM,ERR_SOURCE,CHG_DATE,CHG_USER,CHG_TERM,OVERRIDE_INPUT,MAIL_OPTION) values ('VTWHERECON','Incorrect where condition','Incorrect where condition please check the SQL','E','Y',null,null,null,sysdate,'TSD','TSD',null,null);
Insert into MESSAGES (MSG_NO,MSG_STR,MSG_DESCR,MSG_TYPE,MSG_OPT,MSG_TIME,ALARM,ERR_SOURCE,CHG_DATE,CHG_USER,CHG_TERM,OVERRIDE_INPUT,MAIL_OPTION) values ('VTWHERECLA','Where clause cannot be null','where clause cannot be null if the confirm condition has been specified','E','Y',null,null,null,sysdate,'TSD','TSD',null,null);
Insert into MESSAGES (MSG_NO,MSG_STR,MSG_DESCR,MSG_TYPE,MSG_OPT,MSG_TIME,ALARM,ERR_SOURCE,CHG_DATE,CHG_USER,CHG_TERM,OVERRIDE_INPUT,MAIL_OPTION) values ('VTTABNULL','Table name cannot be blank','Table name cannot be blank','E','Y',null,null,null,sysdate,'TSD','TSD',null,null);
-----------------------------------------given entry for the release
......@@ -3,9 +3,9 @@
<Sybase_eDataWindow>
<Release>9</Release>
<BaseDefinition>
<units>1</units>
<units>0</units>
<timer_interval>0</timer_interval>
<color>1073741824</color>
<color>79741120</color>
<processing>1</processing>
<HTMLDW>no</HTMLDW>
<print>
......@@ -13,10 +13,10 @@
<printername></printername>
<orientation>0</orientation>
<margin>
<left>24</left>
<right>24</right>
<top>24</top>
<bottom>24</bottom>
<left>110</left>
<right>110</right>
<top>96</top>
<bottom>96</bottom>
</margin>
<paper>
<source>0</source>
......@@ -32,7 +32,7 @@
<grid.lines>0</grid.lines>
</BaseDefinition>
<Header>
<height>20</height>
<height>80</height>
<color>536870912</color>
</Header>
<Summary>
......@@ -44,7 +44,7 @@
<color>536870912</color>
</Footer>
<Detail>
<height>23</height>
<height>92</height>
<color>536870912</color>
</Detail>
<TableDefinition>
......@@ -77,20 +77,6 @@
<name>sqlselect</name>
<dbname>emptransfersql.sqlselect</dbname>
</table_column>
<table_column>
<type size="15">char</type>
<update>yes</update>
<updatewhereclause>yes</updatewhereclause>
<name>tran_no_fld</name>
<dbname>emptransfersql.tran_no_fld</dbname>
</table_column>
<table_column>
<type size="15">char</type>
<update>yes</update>
<updatewhereclause>yes</updatewhereclause>
<name>tran_no_fld_val</name>
<dbname>emptransfersql.tran_no_fld_val</dbname>
</table_column>
<table_column>
<type precision="0">decimal</type>
<update>yes</update>
......@@ -112,6 +98,20 @@
<name>where_cond</name>
<dbname>emptransfersql.where_cond</dbname>
</table_column>
<table_column>
<type size="15">char</type>
<update>yes</update>
<updatewhereclause>yes</updatewhereclause>
<name>tran_no_fld</name>
<dbname>emptransfersql.tran_no_fld</dbname>
</table_column>
<table_column>
<type size="15">char</type>
<update>yes</update>
<updatewhereclause>yes</updatewhereclause>
<name>tran_no_fld_val</name>
<dbname>emptransfersql.tran_no_fld_val</dbname>
</table_column>
<table_column>
<type size="10">char</type>
<update>yes</update>
......@@ -127,20 +127,13 @@
<dbname>emptransfersql.chg_date</dbname>
</table_column>
<table_column>
<type size="15">char</type>
<type size="300">char</type>
<update>yes</update>
<updatewhereclause>yes</updatewhereclause>
<name>chg_term</name>
<dbname>emptransfersql.chg_term</dbname>
</table_column>
<table_column>
<type size="1">char</type>
<update>yes</update>
<updatewhereclause>yes</updatewhereclause>
<name>sql_flag</name>
<dbname>emptransfersql.sql_flag</dbname>
</table_column>
<retrieve>PBSELECT( VERSION(400) TABLE(NAME=&quot;emptransfersql&quot; ) COLUMN(NAME=&quot;emptransfersql.table_no&quot;) COLUMN(NAME=&quot;emptransfersql.table_name&quot;) COLUMN(NAME=&quot;emptransfersql.prim_key&quot;) COLUMN(NAME=&quot;emptransfersql.sqlselect&quot;) COLUMN(NAME=&quot;emptransfersql.tran_no_fld&quot;) COLUMN(NAME=&quot;emptransfersql.tran_no_fld_val&quot;) COLUMN(NAME=&quot;emptransfersql.numrows&quot;) COLUMN(NAME=&quot;emptransfersql.confirm_condition&quot;) COLUMN(NAME=&quot;emptransfersql.where_cond&quot;) COLUMN(NAME=&quot;emptransfersql.chg_user&quot;) COLUMN(NAME=&quot;emptransfersql.chg_date&quot;) COLUMN(NAME=&quot;emptransfersql.chg_term&quot;) COLUMN(NAME=&quot;emptransfersql.sql_flag&quot;)) </retrieve>
<retrieve>PBSELECT( VERSION(400) TABLE(NAME=&quot;emptransfersql&quot; ) COLUMN(NAME=&quot;emptransfersql.table_no&quot;) COLUMN(NAME=&quot;emptransfersql.table_name&quot;) COLUMN(NAME=&quot;emptransfersql.prim_key&quot;) COLUMN(NAME=&quot;emptransfersql.sqlselect&quot;) COLUMN(NAME=&quot;emptransfersql.numrows&quot;) COLUMN(NAME=&quot;emptransfersql.confirm_condition&quot;) COLUMN(NAME=&quot;emptransfersql.where_cond&quot;) COLUMN(NAME=&quot;emptransfersql.tran_no_fld&quot;) COLUMN(NAME=&quot;emptransfersql.tran_no_fld_val&quot;) COLUMN(NAME=&quot;emptransfersql.chg_user&quot;) COLUMN(NAME=&quot;emptransfersql.chg_date&quot;) COLUMN(NAME=&quot;emptransfersql.chg_term&quot;)) </retrieve>
<update>EMPTRANSFERSQL</update>
<updatewhere>0</updatewhere>
<updatekeyinplace>no</updatekeyinplace>
......@@ -149,22 +142,22 @@
<band>Header</band>
<alignment>2</alignment>
<text>Table No</text>
<border>0</border>
<color>33554432</color>
<x>2</x>
<y>2</y>
<height>16</height>
<width>49</width>
<border>6</border>
<color>0</color>
<x>9</x>
<y>8</y>
<height>64</height>
<width>274</width>
<html>
<valueishtml>0</valueishtml>
</html>
<name>table_no_t</name>
<visible>1</visible>
<font>
<face>Arial</face>
<face>Times New Roman</face>
<height>-10</height>
<weight>400</weight>
<family>2</family>
<family>1</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
......@@ -177,22 +170,22 @@
<band>Header</band>
<alignment>2</alignment>
<text>Table Name</text>
<border>0</border>
<color>33554432</color>
<x>53</x>
<y>2</y>
<height>16</height>
<width>121</width>
<border>6</border>
<color>0</color>
<x>293</x>
<y>8</y>
<height>64</height>
<width>709</width>
<html>
<valueishtml>0</valueishtml>
</html>
<name>table_name_t</name>
<visible>1</visible>
<font>
<face>Arial</face>
<face>Times New Roman</face>
<height>-10</height>
<weight>400</weight>
<family>2</family>
<family>1</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
......@@ -204,51 +197,23 @@
<TextObject>
<band>Header</band>
<alignment>2</alignment>
<text>Prim Key</text>
<border>0</border>
<color>33554432</color>
<x>176</x>
<y>2</y>
<height>16</height>
<width>241</width>
<text>Primary Key</text>
<border>6</border>
<color>0</color>
<x>1010</x>
<y>8</y>
<height>64</height>
<width>2309</width>
<html>
<valueishtml>0</valueishtml>
</html>
<name>prim_key_t</name>
<visible>1</visible>
<font>
<face>Arial</face>
<height>-10</height>
<weight>400</weight>
<family>2</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
<background>
<mode>1</mode>
<color>536870912</color>
</background>
</TextObject>
<TextObject>
<band>Header</band>
<alignment>2</alignment>
<text>Tran No Fld</text>
<border>0</border>
<color>33554432</color>
<x>612</x>
<y>2</y>
<height>16</height>
<width>96</width>
<html>
<valueishtml>0</valueishtml>
</html>
<name>tran_no_fld_t</name>
<visible>1</visible>
<font>
<face>Arial</face>
<face>Times New Roman</face>
<height>-10</height>
<weight>400</weight>
<family>2</family>
<family>1</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
......@@ -260,23 +225,23 @@
<TextObject>
<band>Header</band>
<alignment>2</alignment>
<text>Tran No Fld Val</text>
<border>0</border>
<color>33554432</color>
<x>710</x>
<y>2</y>
<height>16</height>
<width>96</width>
<text>Sqlselect</text>
<border>6</border>
<color>0</color>
<x>3328</x>
<y>8</y>
<height>64</height>
<width>4759</width>
<html>
<valueishtml>0</valueishtml>
</html>
<name>tran_no_fld_val_t</name>
<name>sqlselect_t</name>
<visible>1</visible>
<font>
<face>Arial</face>
<face>Times New Roman</face>
<height>-10</height>
<weight>400</weight>
<family>2</family>
<family>1</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
......@@ -288,23 +253,23 @@
<TextObject>
<band>Header</band>
<alignment>2</alignment>
<text>Numrows</text>
<border>0</border>
<color>33554432</color>
<x>808</x>
<y>2</y>
<height>16</height>
<width>72</width>
<text>Tran No Fld</text>
<border>6</border>
<color>0</color>
<x>8096</x>
<y>8</y>
<height>64</height>
<width>366</width>
<html>
<valueishtml>0</valueishtml>
</html>
<name>numrows_t</name>
<name>tran_no_fld_t</name>
<visible>1</visible>
<font>
<face>Arial</face>
<face>Times New Roman</face>
<height>-10</height>
<weight>400</weight>
<family>2</family>
<family>1</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
......@@ -316,23 +281,23 @@
<TextObject>
<band>Header</band>
<alignment>2</alignment>
<text>Confirm Condition</text>
<border>0</border>
<color>33554432</color>
<x>882</x>
<y>2</y>
<height>16</height>
<width>281</width>
<text>Tran No Fld Val</text>
<border>6</border>
<color>0</color>
<x>8471</x>
<y>8</y>
<height>64</height>
<width>384</width>
<html>
<valueishtml>0</valueishtml>
</html>
<name>confirm_condition_t</name>
<name>tran_no_fld_val_t</name>
<visible>1</visible>
<font>
<face>Arial</face>
<face>Times New Roman</face>
<height>-10</height>
<weight>400</weight>
<family>2</family>
<family>1</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
......@@ -344,23 +309,23 @@
<TextObject>
<band>Header</band>
<alignment>2</alignment>
<text>Where Cond</text>
<border>0</border>
<color>33554432</color>
<x>1165</x>
<y>2</y>
<height>16</height>
<width>335</width>
<text>Numrows</text>
<border>6</border>
<color>0</color>
<x>8864</x>
<y>8</y>
<height>64</height>
<width>274</width>
<html>
<valueishtml>0</valueishtml>
</html>
<name>where_cond_t</name>
<name>numrows_t</name>
<visible>1</visible>
<font>
<face>Arial</face>
<face>Times New Roman</face>
<height>-10</height>
<weight>400</weight>
<family>2</family>
<family>1</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
......@@ -372,141 +337,141 @@
<TextObject>
<band>Header</band>
<alignment>2</alignment>
<text>Chg User</text>
<border>0</border>
<color>33554432</color>
<x>1502</x>
<y>2</y>
<height>16</height>
<width>66</width>
<text>Confirm Condition</text>
<border>6</border>
<color>0</color>
<x>9147</x>
<y>8</y>
<height>64</height>
<width>2743</width>
<html>
<valueishtml>0</valueishtml>
</html>
<name>chg_user_t</name>
<name>confirm_condition_t</name>
<visible>1</visible>
<font>
<face>Arial</face>
<face>Times New Roman</face>
<height>-10</height>
<weight>400</weight>
<family>2</family>
<family>1</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
<background>
<mode>1</mode>
<color>536870912</color>
<mode>2</mode>
<color>79741120</color>
</background>
</TextObject>
<TextObject>
<band>Header</band>
<alignment>2</alignment>
<text>Chg Date</text>
<border>0</border>
<color>33554432</color>
<x>1570</x>
<y>2</y>
<height>16</height>
<width>132</width>
<text>Where Cond</text>
<border>6</border>
<color>0</color>
<x>11899</x>
<y>8</y>
<height>64</height>
<width>2734</width>
<html>
<valueishtml>0</valueishtml>
</html>
<name>chg_date_t</name>
<name>where_cond_t</name>
<visible>1</visible>
<font>
<face>Arial</face>
<face>Times New Roman</face>
<height>-10</height>
<weight>400</weight>
<family>2</family>
<family>1</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
<background>
<mode>1</mode>
<color>536870912</color>
<mode>2</mode>
<color>79741120</color>
</background>
</TextObject>
<TextObject>
<band>Header</band>
<alignment>2</alignment>
<text>Chg Term</text>
<border>0</border>
<color>33554432</color>
<x>1704</x>
<y>2</y>
<height>16</height>
<width>96</width>
<alignment>0</alignment>
<text>Chg User</text>
<border>6</border>
<color>0</color>
<x>14642</x>
<y>8</y>
<height>64</height>
<width>338</width>
<html>
<valueishtml>0</valueishtml>
</html>
<name>chg_term_t</name>
<name>chg_user_t</name>
<visible>1</visible>
<font>
<face>Arial</face>
<face>Times New Roman</face>
<height>-10</height>
<weight>400</weight>
<family>2</family>
<family>1</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
<background>
<mode>1</mode>
<color>536870912</color>
<mode>2</mode>
<color>79741120</color>
</background>
</TextObject>
<TextObject>
<band>Header</band>
<alignment>2</alignment>
<text>Sql Flag</text>
<border>0</border>
<color>33554432</color>
<x>1802</x>
<y>2</y>
<height>16</height>
<width>48</width>
<alignment>0</alignment>
<text>Chg Date</text>
<border>6</border>
<color>0</color>
<x>14990</x>
<y>8</y>
<height>64</height>
<width>507</width>
<html>
<valueishtml>0</valueishtml>
</html>
<name>sql_flag_t</name>
<name>chg_date_t</name>
<visible>1</visible>
<font>
<face>Arial</face>
<face>Times New Roman</face>
<height>-10</height>
<weight>400</weight>
<family>2</family>
<family>1</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
<background>
<mode>1</mode>
<color>536870912</color>
<mode>2</mode>
<color>79741120</color>
</background>
</TextObject>
<TextObject>
<band>Header</band>
<alignment>2</alignment>
<text>Sqlselect</text>
<border>0</border>
<color>33554432</color>
<x>419</x>
<y>2</y>
<height>16</height>
<width>191</width>
<alignment>0</alignment>
<text>Chg Term</text>
<border>6</border>
<color>0</color>
<x>15506</x>
<y>8</y>
<height>64</height>
<width>334</width>
<html>
<valueishtml>0</valueishtml>
</html>
<name>sqlselect_t</name>
<name>chg_term_t</name>
<visible>1</visible>
<font>
<face>Arial</face>
<face>Times New Roman</face>
<height>-10</height>
<weight>400</weight>
<family>2</family>
<family>1</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
<background>
<mode>1</mode>
<color>536870912</color>
<mode>2</mode>
<color>79741120</color>
</background>
</TextObject>
<ColumnObject>
......@@ -514,12 +479,12 @@
<id>1</id>
<alignment>1</alignment>
<tabsequence>10</tabsequence>
<border>0</border>
<color>33554432</color>
<x>2</x>
<y>2</y>
<height>19</height>
<width>49</width>
<border>5</border>
<color>0</color>
<x>9</x>
<y>8</y>
<height>76</height>
<width>274</width>
<format>[general]</format>
<html>
<valueishtml>0</valueishtml>
......@@ -535,16 +500,16 @@
<imemode>0</imemode>
</EditStyle>
<font>
<face>Arial</face>
<face>Times New Roman</face>
<height>-10</height>
<weight>400</weight>
<family>2</family>
<family>1</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
<background>
<mode>1</mode>
<color>536870912</color>
<mode>2</mode>
<color>1090519039</color>
</background>
</ColumnObject>
<ColumnObject>
......@@ -552,12 +517,12 @@
<id>2</id>
<alignment>0</alignment>
<tabsequence>20</tabsequence>
<border>0</border>
<color>33554432</color>
<x>53</x>
<y>2</y>
<height>19</height>
<width>121</width>
<border>5</border>
<color>0</color>
<x>293</x>
<y>8</y>
<height>76</height>
<width>709</width>
<format>[general]</format>
<html>
<valueishtml>0</valueishtml>
......@@ -573,16 +538,16 @@
<imemode>0</imemode>
</EditStyle>
<font>
<face>Arial</face>
<face>Times New Roman</face>
<height>-10</height>
<weight>400</weight>
<family>2</family>
<family>1</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
<background>
<mode>1</mode>
<color>536870912</color>
<mode>2</mode>
<color>1090519039</color>
</background>
</ColumnObject>
<ColumnObject>
......@@ -590,12 +555,12 @@
<id>3</id>
<alignment>0</alignment>
<tabsequence>30</tabsequence>
<border>0</border>
<color>33554432</color>
<x>176</x>
<y>2</y>
<height>19</height>
<width>241</width>
<border>5</border>
<color>0</color>
<x>1010</x>
<y>8</y>
<height>76</height>
<width>2309</width>
<format>[general]</format>
<html>
<valueishtml>0</valueishtml>
......@@ -611,37 +576,37 @@
<imemode>0</imemode>
</EditStyle>
<font>
<face>Arial</face>
<face>Times New Roman</face>
<height>-10</height>
<weight>400</weight>
<family>2</family>
<family>1</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
<background>
<mode>1</mode>
<color>536870912</color>
<mode>2</mode>
<color>1090519039</color>
</background>
</ColumnObject>
<ColumnObject>
<band>Detail</band>
<id>5</id>
<id>4</id>
<alignment>0</alignment>
<tabsequence>50</tabsequence>
<border>0</border>
<color>33554432</color>
<x>612</x>
<y>2</y>
<height>19</height>
<width>96</width>
<tabsequence>40</tabsequence>
<border>5</border>
<color>0</color>
<x>3328</x>
<y>8</y>
<height>76</height>
<width>4759</width>
<format>[general]</format>
<html>
<valueishtml>0</valueishtml>
</html>
<name>tran_no_fld</name>
<name>sqlselect</name>
<visible>1</visible>
<EditStyle style="edit">
<limit>15</limit>
<limit>1500</limit>
<case>any</case>
<focusrectangle>no</focusrectangle>
<autoselect>yes</autoselect>
......@@ -649,34 +614,34 @@
<imemode>0</imemode>
</EditStyle>
<font>
<face>Arial</face>
<face>Times New Roman</face>
<height>-10</height>
<weight>400</weight>
<family>2</family>
<family>1</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
<background>
<mode>1</mode>
<color>536870912</color>
<mode>2</mode>
<color>1090519039</color>
</background>
</ColumnObject>
<ColumnObject>
<band>Detail</band>
<id>6</id>
<id>8</id>
<alignment>0</alignment>
<tabsequence>60</tabsequence>
<border>0</border>
<color>33554432</color>
<x>710</x>
<y>2</y>
<height>19</height>
<width>96</width>
<tabsequence>50</tabsequence>
<border>5</border>
<color>0</color>
<x>8096</x>
<y>8</y>
<height>76</height>
<width>366</width>
<format>[general]</format>
<html>
<valueishtml>0</valueishtml>
</html>
<name>tran_no_fld_val</name>
<name>tran_no_fld</name>
<visible>1</visible>
<EditStyle style="edit">
<limit>15</limit>
......@@ -687,75 +652,37 @@
<imemode>0</imemode>
</EditStyle>
<font>
<face>Arial</face>
<height>-10</height>
<weight>400</weight>
<family>2</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
<background>
<mode>1</mode>
<color>536870912</color>
</background>
</ColumnObject>
<ColumnObject>
<band>Detail</band>
<id>7</id>
<alignment>1</alignment>
<tabsequence>70</tabsequence>
<border>0</border>
<color>33554432</color>
<x>808</x>
<y>2</y>
<height>19</height>
<width>72</width>
<format>[general]</format>
<html>
<valueishtml>0</valueishtml>
</html>
<name>numrows</name>
<visible>1</visible>
<EditStyle style="edit">
<limit>0</limit>
<case>any</case>
<focusrectangle>no</focusrectangle>
<autoselect>yes</autoselect>
<autohscroll>yes</autohscroll>
<imemode>0</imemode>
</EditStyle>
<font>
<face>Arial</face>
<face>Times New Roman</face>
<height>-10</height>
<weight>400</weight>
<family>2</family>
<family>1</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
<background>
<mode>1</mode>
<color>536870912</color>
<mode>2</mode>
<color>1090519039</color>
</background>
</ColumnObject>
<ColumnObject>
<band>Detail</band>
<id>8</id>
<id>9</id>
<alignment>0</alignment>
<tabsequence>80</tabsequence>
<border>0</border>
<color>33554432</color>
<x>882</x>
<y>2</y>
<height>19</height>
<width>281</width>
<tabsequence>60</tabsequence>
<border>5</border>
<color>0</color>
<x>8471</x>
<y>8</y>
<height>76</height>
<width>384</width>
<format>[general]</format>
<html>
<valueishtml>0</valueishtml>
</html>
<name>confirm_condition</name>
<name>tran_no_fld_val</name>
<visible>1</visible>
<EditStyle style="edit">
<limit>300</limit>
<limit>15</limit>
<case>any</case>
<focusrectangle>no</focusrectangle>
<autoselect>yes</autoselect>
......@@ -763,37 +690,37 @@
<imemode>0</imemode>
</EditStyle>
<font>
<face>Arial</face>
<face>Times New Roman</face>
<height>-10</height>
<weight>400</weight>
<family>2</family>
<family>1</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
<background>
<mode>1</mode>
<color>536870912</color>
<mode>2</mode>
<color>1090519039</color>
</background>
</ColumnObject>
<ColumnObject>
<band>Detail</band>
<id>9</id>
<alignment>0</alignment>
<tabsequence>90</tabsequence>
<border>0</border>
<color>33554432</color>
<x>1165</x>
<y>2</y>
<height>19</height>
<width>335</width>
<id>5</id>
<alignment>1</alignment>
<tabsequence>70</tabsequence>
<border>5</border>
<color>0</color>
<x>8864</x>
<y>8</y>
<height>76</height>
<width>274</width>
<format>[general]</format>
<html>
<valueishtml>0</valueishtml>
</html>
<name>where_cond</name>
<name>numrows</name>
<visible>1</visible>
<EditStyle style="edit">
<limit>500</limit>
<limit>0</limit>
<case>any</case>
<focusrectangle>no</focusrectangle>
<autoselect>yes</autoselect>
......@@ -801,37 +728,37 @@
<imemode>0</imemode>
</EditStyle>
<font>
<face>Arial</face>
<face>Times New Roman</face>
<height>-10</height>
<weight>400</weight>
<family>2</family>
<family>1</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
<background>
<mode>1</mode>
<color>536870912</color>
<mode>2</mode>
<color>1090519039</color>
</background>
</ColumnObject>
<ColumnObject>
<band>Detail</band>
<id>10</id>
<id>6</id>
<alignment>0</alignment>
<tabsequence>100</tabsequence>
<border>0</border>
<color>33554432</color>
<x>1502</x>
<y>2</y>
<height>19</height>
<width>66</width>
<tabsequence>80</tabsequence>
<border>5</border>
<color>0</color>
<x>9147</x>
<y>8</y>
<height>76</height>
<width>2743</width>
<format>[general]</format>
<html>
<valueishtml>0</valueishtml>
</html>
<name>chg_user</name>
<name>confirm_condition</name>
<visible>1</visible>
<EditStyle style="edit">
<limit>10</limit>
<limit>300</limit>
<case>any</case>
<focusrectangle>no</focusrectangle>
<autoselect>yes</autoselect>
......@@ -839,168 +766,159 @@
<imemode>0</imemode>
</EditStyle>
<font>
<face>Arial</face>
<face>Times New Roman</face>
<height>-10</height>
<weight>400</weight>
<family>2</family>
<family>1</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
<background>
<mode>1</mode>
<color>536870912</color>
<mode>2</mode>
<color>1090519039</color>
</background>
</ColumnObject>
<ColumnObject>
<band>Detail</band>
<id>11</id>
<id>7</id>
<alignment>0</alignment>
<tabsequence>110</tabsequence>
<border>0</border>
<color>33554432</color>
<x>1570</x>
<y>2</y>
<height>19</height>
<width>132</width>
<format>[shortdate] [time]</format>
<tabsequence>32766</tabsequence>
<border>5</border>
<color>0</color>
<x>11899</x>
<y>12</y>
<height>64</height>
<width>2734</width>
<format>[general]</format>
<html>
<valueishtml>0</valueishtml>
</html>
<name>chg_date</name>
<name>where_cond</name>
<visible>1</visible>
<EditStyle style="edit">
<limit>0</limit>
<case>any</case>
<focusrectangle>no</focusrectangle>
<autoselect>yes</autoselect>
<autohscroll>yes</autohscroll>
<imemode>0</imemode>
</EditStyle>
<font>
<face>Arial</face>
<face>Times New Roman</face>
<height>-10</height>
<weight>400</weight>
<family>2</family>
<family>1</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
<background>
<mode>1</mode>
<color>536870912</color>
<mode>2</mode>
<color>1090519039</color>
</background>
</ColumnObject>
<ColumnObject>
<band>Detail</band>
<id>12</id>
<id>10</id>
<alignment>0</alignment>
<tabsequence>120</tabsequence>
<border>0</border>
<color>33554432</color>
<x>1704</x>
<y>2</y>
<height>19</height>
<width>96</width>
<tabsequence>32766</tabsequence>
<border>5</border>
<color>0</color>
<x>14642</x>
<y>12</y>
<height>64</height>
<width>338</width>
<format>[general]</format>
<html>
<valueishtml>0</valueishtml>
</html>
<name>chg_term</name>
<name>chg_user</name>
<visible>1</visible>
<EditStyle style="edit">
<limit>15</limit>
<limit>0</limit>
<case>any</case>
<focusrectangle>no</focusrectangle>
<autoselect>yes</autoselect>
<autohscroll>yes</autohscroll>
<imemode>0</imemode>
</EditStyle>
<font>
<face>Arial</face>
<face>Times New Roman</face>
<height>-10</height>
<weight>400</weight>
<family>2</family>
<family>1</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
<background>
<mode>1</mode>
<color>536870912</color>
<mode>2</mode>
<color>1090519039</color>
</background>
</ColumnObject>
<ColumnObject>
<band>Detail</band>
<id>13</id>
<id>11</id>
<alignment>0</alignment>
<tabsequence>130</tabsequence>
<border>0</border>
<color>33554432</color>
<x>1802</x>
<y>2</y>
<height>19</height>
<width>48</width>
<format>[general]</format>
<tabsequence>32766</tabsequence>
<border>5</border>
<color>0</color>
<x>14990</x>
<y>12</y>
<height>64</height>
<width>507</width>
<format>dd/mm/yy</format>
<html>
<valueishtml>0</valueishtml>
</html>
<name>sql_flag</name>
<name>chg_date</name>
<visible>1</visible>
<EditStyle style="edit">
<limit>1</limit>
<case>any</case>
<focusrectangle>no</focusrectangle>
<autoselect>yes</autoselect>
<autohscroll>yes</autohscroll>
<EditStyle style="editmask">
<mask>dd/mm/yy</mask>
<imemode>0</imemode>
<focusrectangle>no</focusrectangle>
</EditStyle>
<font>
<face>Arial</face>
<face>Times New Roman</face>
<height>-10</height>
<weight>400</weight>
<family>2</family>
<family>1</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
<background>
<mode>1</mode>
<color>536870912</color>
<mode>2</mode>
<color>1090519039</color>
</background>
</ColumnObject>
<ColumnObject>
<band>Detail</band>
<id>4</id>
<id>12</id>
<alignment>0</alignment>
<tabsequence>40</tabsequence>
<border>0</border>
<color>33554432</color>
<x>419</x>
<y>2</y>
<height>19</height>
<width>191</width>
<tabsequence>32766</tabsequence>
<border>5</border>
<color>0</color>
<x>15506</x>
<y>12</y>
<height>64</height>
<width>334</width>
<format>[general]</format>
<html>
<valueishtml>0</valueishtml>
</html>
<name>sqlselect</name>
<name>chg_term</name>
<visible>1</visible>
<EditStyle style="edit">
<limit>2000</limit>
<limit>0</limit>
<case>any</case>
<focusrectangle>no</focusrectangle>
<autoselect>yes</autoselect>
<autohscroll>yes</autohscroll>
<imemode>0</imemode>
</EditStyle>
<font>
<face>Arial</face>
<face>Times New Roman</face>
<height>-10</height>
<weight>400</weight>
<family>2</family>
<family>1</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
<background>
<mode>1</mode>
<color>536870912</color>
<mode>2</mode>
<color>1090519039</color>
</background>
</ColumnObject>
<HtmlTable>
......
......@@ -5,7 +5,7 @@
<BaseDefinition>
<units>1</units>
<timer_interval>0</timer_interval>
<color>1073741824</color>
<color>79741120</color>
<processing>0</processing>
<HTMLDW>no</HTMLDW>
<print>
......@@ -30,10 +30,6 @@
<overrideprintjob>no</overrideprintjob>
</print>
</BaseDefinition>
<Header>
<height>5</height>
<color>536870912</color>
</Header>
<Summary>
<height>0</height>
<color>536870912</color>
......@@ -43,7 +39,7 @@
<color>536870912</color>
</Footer>
<Detail>
<height>631</height>
<height>594</height>
<color>536870912</color>
</Detail>
<TableDefinition>
......@@ -90,6 +86,27 @@
<name>where_cond</name>
<dbname>emptransfersql.where_cond</dbname>
</table_column>
<table_column>
<type size="10">char</type>
<update>yes</update>
<updatewhereclause>yes</updatewhereclause>
<name>chg_user</name>
<dbname>emptransfersql.chg_user</dbname>
</table_column>
<table_column>
<type>datetime</type>
<update>yes</update>
<updatewhereclause>yes</updatewhereclause>
<name>chg_date</name>
<dbname>emptransfersql.chg_date</dbname>
</table_column>
<table_column>
<type size="300">char</type>
<update>yes</update>
<updatewhereclause>yes</updatewhereclause>
<name>chg_term</name>
<dbname>emptransfersql.chg_term</dbname>
</table_column>
<table_column>
<type size="1">char</type>
<update>yes</update>
......@@ -97,33 +114,65 @@
<name>sql_flag</name>
<dbname>emptransfersql.sql_flag</dbname>
<values>
<item display="Delete &amp; Insert" data="D"/>
<item display="Delete and Insert" data="D"/>
<item display="Insert" data="I"/>
</values>
</table_column>
<retrieve>PBSELECT( VERSION(400) TABLE(NAME=&quot;emptransfersql&quot; ) COLUMN(NAME=&quot;emptransfersql.table_no&quot;) COLUMN(NAME=&quot;emptransfersql.table_name&quot;) COLUMN(NAME=&quot;emptransfersql.prim_key&quot;) COLUMN(NAME=&quot;emptransfersql.sqlselect&quot;) COLUMN(NAME=&quot;emptransfersql.confirm_condition&quot;) COLUMN(NAME=&quot;emptransfersql.where_cond&quot;) COLUMN(NAME=&quot;emptransfersql.sql_flag&quot;)WHERE( EXP1 =&quot;~&quot;EMPTRANSFERSQL~&quot;.~&quot;TABLE_NO~&quot;&quot; OP =&quot;=&quot; EXP2 =&quot;:table_no&quot; ) ) ARG(NAME = &quot;table_no&quot; TYPE = number) </retrieve>
<table_column>
<type size="1">char</type>
<updatewhereclause>yes</updatewhereclause>
<name>table_name_old</name>
<dbname>table_name_old</dbname>
</table_column>
<retrieve>PBSELECT( VERSION(400) TABLE(NAME=&quot;emptransfersql&quot; ) COLUMN(NAME=&quot;emptransfersql.table_no&quot;) COLUMN(NAME=&quot;emptransfersql.table_name&quot;) COLUMN(NAME=&quot;emptransfersql.prim_key&quot;) COLUMN(NAME=&quot;emptransfersql.sqlselect&quot;) COLUMN(NAME=&quot;emptransfersql.confirm_condition&quot;) COLUMN(NAME=&quot;emptransfersql.where_cond&quot;) COLUMN(NAME=&quot;emptransfersql.chg_user&quot;) COLUMN(NAME=&quot;emptransfersql.chg_date&quot;) COLUMN(NAME=&quot;emptransfersql.chg_term&quot;) COLUMN(NAME=&quot;emptransfersql.sql_flag&quot;) COMPUTE(NAME=&quot;&apos; &apos; as table_name_old&quot;)WHERE( EXP1 =&quot;emptransfersql.table_no&quot; OP =&quot;=&quot; EXP2 =&quot;:ll_tno&quot; ) ) ARG(NAME = &quot;ll_tno&quot; TYPE = number) </retrieve>
<update>EMPTRANSFERSQL</update>
<updatewhere>1</updatewhere>
<updatewhere>0</updatewhere>
<updatekeyinplace>no</updatekeyinplace>
<argument>
<name>table_no</name>
<name>ll_tno</name>
<type>number</type>
</argument>
<sort>
<expression>table_no A</expression>
</sort>
</TableDefinition>
<GroupBox>
<band>Detail</band>
<text>Employee Transfer SQL</text>
<text>Others</text>
<border>2</border>
<color>33554432</color>
<x>1</x>
<y>0</y>
<height>354</height>
<width>827</width>
<color>0</color>
<x>9</x>
<y>479</y>
<height>61</height>
<width>602</width>
<name>gb_2</name>
<visible>1</visible>
<font>
<face>Liberation Sans</face>
<height>-10</height>
<weight>400</weight>
<family>2</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
<background>
<mode>1</mode>
<color>553648127</color>
</background>
</GroupBox>
<GroupBox>
<band>Detail</band>
<text>Basic</text>
<border>2</border>
<color>0</color>
<x>6</x>
<y>2</y>
<height>465</height>
<width>606</width>
<name>gb_1</name>
<visible>1</visible>
<hidesnaked>1</hidesnaked>
<font>
<face>Arial</face>
<face>Liberation Sans</face>
<height>-12</height>
<weight>400</weight>
<family>2</family>
......@@ -131,162 +180,250 @@
<charset>0</charset>
</font>
<background>
<mode>2</mode>
<color>1073741824</color>
<mode>1</mode>
<color>553648127</color>
</background>
</GroupBox>
<TextObject>
<band>Detail</band>
<alignment>1</alignment>
<text>Table No:</text>
<alignment>0</alignment>
<text>Edit sql :</text>
<border>0</border>
<color>33554432</color>
<x>37</x>
<y>19</y>
<color>0</color>
<x>8</x>
<y>150</y>
<height>16</height>
<width>106</width>
<width>50</width>
<html>
<valueishtml>0</valueishtml>
</html>
<name>table_no_t</name>
<name>t_1</name>
<visible>1</visible>
<font>
<face>Arial</face>
<face>Times New Roman</face>
<height>-10</height>
<weight>400</weight>
<family>2</family>
<family>1</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
<background>
<mode>1</mode>
<color>536870912</color>
<mode>2</mode>
<color>12632256</color>
</background>
</TextObject>
<TextObject>
<band>Detail</band>
<alignment>0</alignment>
<text>Change User:</text>
<border>0</border>
<color>0</color>
<x>18</x>
<y>501</y>
<height>15</height>
<width>99</width>
<html>
<valueishtml>0</valueishtml>
</html>
<name>chg_user_t</name>
<visible>1</visible>
<font>
<face>Times New Roman</face>
<height>-10</height>
<weight>400</weight>
<family>1</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
<background>
<mode>2</mode>
<color>79741120</color>
</background>
</TextObject>
<ColumnObject>
<band>Detail</band>
<id>1</id>
<alignment>1</alignment>
<id>7</id>
<alignment>0</alignment>
<tabsequence>32766</tabsequence>
<border>5</border>
<color>33554432</color>
<x>147</x>
<y>17</y>
<height>19</height>
<width>180</width>
<border>0</border>
<color>0</color>
<x>120</x>
<y>501</y>
<height>16</height>
<width>51</width>
<format>[general]</format>
<html>
<valueishtml>0</valueishtml>
</html>
<name>table_no</name>
<visible>1</visible>
<name>chg_user</name>
<visible expression="0">1</visible>
<EditStyle style="edit">
<limit>0</limit>
<case>any</case>
<focusrectangle>no</focusrectangle>
<autoselect>yes</autoselect>
<autohscroll>yes</autohscroll>
<imemode>0</imemode>
</EditStyle>
<font>
<face>Arial</face>
<face>Times New Roman</face>
<height>-10</height>
<weight>400</weight>
<family>2</family>
<family>1</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
<background>
<mode>1</mode>
<color>536870912</color>
<mode>2</mode>
<color>16777215</color>
</background>
</ColumnObject>
<TextObject>
<band>Detail</band>
<alignment>0</alignment>
<text>Change Term:</text>
<border>0</border>
<color>0</color>
<x>404</x>
<y>501</y>
<height>15</height>
<width>99</width>
<html>
<valueishtml>0</valueishtml>
</html>
<name>chg_term_t</name>
<visible>1</visible>
<font>
<face>Times New Roman</face>
<height>-10</height>
<weight>400</weight>
<family>1</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
<background>
<mode>2</mode>
<color>79741120</color>
</background>
</TextObject>
<ColumnObject>
<band>Detail</band>
<id>3</id>
<id>9</id>
<alignment>0</alignment>
<tabsequence>20</tabsequence>
<border>5</border>
<color>33554432</color>
<x>147</x>
<y>43</y>
<height>19</height>
<width>483</width>
<tabsequence>32766</tabsequence>
<border>0</border>
<color>0</color>
<x>507</x>
<y>501</y>
<height>16</height>
<width>76</width>
<format>[general]</format>
<html>
<valueishtml>0</valueishtml>
</html>
<name>prim_key</name>
<visible>1</visible>
<name>chg_term</name>
<visible expression="0">1</visible>
<EditStyle style="edit">
<limit>100</limit>
<limit>0</limit>
<case>any</case>
<focusrectangle>no</focusrectangle>
<autoselect>yes</autoselect>
<autohscroll>yes</autohscroll>
<imemode>0</imemode>
</EditStyle>
<font>
<face>Arial</face>
<face>Times New Roman</face>
<height>-10</height>
<weight>400</weight>
<family>2</family>
<family>1</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
<background>
<mode>1</mode>
<color>536870912</color>
<mode>2</mode>
<color>16777215</color>
</background>
</ColumnObject>
<TextObject>
<ColumnObject>
<band>Detail</band>
<alignment>1</alignment>
<text>Prim Key:</text>
<id>8</id>
<alignment>0</alignment>
<tabsequence>32766</tabsequence>
<border>0</border>
<color>33554432</color>
<x>36</x>
<y>44</y>
<color>0</color>
<x>298</x>
<y>501</y>
<height>16</height>
<width>106</width>
<width>70</width>
<format>[shortdate] [time]</format>
<html>
<valueishtml>0</valueishtml>
</html>
<name>prim_key_t</name>
<name>chg_date</name>
<visible expression="0">1</visible>
<EditStyle style="edit">
<limit>0</limit>
<case>any</case>
<autoselect>yes</autoselect>
<imemode>0</imemode>
</EditStyle>
<font>
<face>Times New Roman</face>
<height>-10</height>
<weight>400</weight>
<family>1</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
<background>
<mode>2</mode>
<color>16777215</color>
</background>
</ColumnObject>
<TextObject>
<band>Detail</band>
<alignment>0</alignment>
<text>Change Date:</text>
<border>0</border>
<color>0</color>
<x>195</x>
<y>501</y>
<height>15</height>
<width>99</width>
<html>
<valueishtml>0</valueishtml>
</html>
<name>chg_date_t</name>
<visible>1</visible>
<font>
<face>Arial</face>
<face>Times New Roman</face>
<height>-10</height>
<weight>400</weight>
<family>2</family>
<family>1</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
<background>
<mode>1</mode>
<color>536870912</color>
<mode>2</mode>
<color>79741120</color>
</background>
</TextObject>
<TextObject>
<band>Detail</band>
<alignment>1</alignment>
<text>Sqlselect:</text>
<text>Table Name:</text>
<border>0</border>
<color>33554432</color>
<x>35</x>
<y>74</y>
<color>0</color>
<x>264</x>
<y>22</y>
<height>16</height>
<width>106</width>
<width>101</width>
<html>
<valueishtml>0</valueishtml>
</html>
<name>sqlselect_t</name>
<name>table_name_t</name>
<visible>1</visible>
<font>
<face>Arial</face>
<face>Times New Roman</face>
<height>-10</height>
<weight>400</weight>
<family>2</family>
<family>1</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
......@@ -297,23 +434,61 @@
</TextObject>
<ColumnObject>
<band>Detail</band>
<id>4</id>
<id>2</id>
<alignment>0</alignment>
<tabsequence>30</tabsequence>
<tabsequence>10</tabsequence>
<border>5</border>
<color>33554432</color>
<x>147</x>
<y>72</y>
<height>114</height>
<width>483</width>
<color>0</color>
<x>369</x>
<y>22</y>
<height>19</height>
<width>224</width>
<format>[general]</format>
<html>
<valueishtml>0</valueishtml>
</html>
<name>sqlselect</name>
<name>table_name</name>
<visible>1</visible>
<EditStyle style="edit">
<limit>2000</limit>
<limit>30</limit>
<case>upper</case>
<focusrectangle>no</focusrectangle>
<autoselect>yes</autoselect>
<autohscroll>yes</autohscroll>
<imemode>0</imemode>
</EditStyle>
<font>
<face>Times New Roman</face>
<height>-10</height>
<weight>400</weight>
<family>1</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
<background>
<mode>2</mode>
<color>16777215</color>
</background>
</ColumnObject>
<ColumnObject>
<band>Detail</band>
<id>5</id>
<alignment>0</alignment>
<tabsequence>40</tabsequence>
<border>5</border>
<color>0</color>
<x>115</x>
<y>367</y>
<height>19</height>
<width>479</width>
<format>[general]</format>
<html>
<valueishtml>0</valueishtml>
</html>
<name>confirm_condition</name>
<visible>1</visible>
<EditStyle style="edit">
<limit>300</limit>
<case>any</case>
<focusrectangle>no</focusrectangle>
<autoselect>yes</autoselect>
......@@ -321,65 +496,104 @@
<imemode>0</imemode>
</EditStyle>
<font>
<face>Arial</face>
<face>Times New Roman</face>
<height>-10</height>
<weight>400</weight>
<family>2</family>
<family>1</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
<background>
<mode>1</mode>
<color>536870912</color>
<mode>2</mode>
<color>16777215</color>
</background>
</ColumnObject>
<TextObject>
<ButtonObject>
<band>Detail</band>
<alignment>1</alignment>
<text>Table Name:</text>
<text>none</text>
<filename>C:\appl\ITM2\BMP\Edit.bmp</filename>
<enabled>yes</enabled>
<action>0</action>
<border>0</border>
<color>33554432</color>
<x>341</x>
<y>18</y>
<height>16</height>
<width>79</width>
<color>0</color>
<x>74</x>
<y>115</y>
<height>24</height>
<width>24</width>
<vtextalign>0</vtextalign>
<htextalign>0</htextalign>
<name>cb_edit</name>
<visible>1</visible>
<font>
<face>Arial</face>
<height>-12</height>
<weight>400</weight>
<family>2</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
<background>
<mode>2</mode>
<color>12632256</color>
</background>
</ButtonObject>
<ColumnObject>
<band>Detail</band>
<id>1</id>
<alignment>1</alignment>
<tabsequence>32766</tabsequence>
<border>5</border>
<color>255</color>
<x>116</x>
<y>22</y>
<height>19</height>
<width>141</width>
<format>[general]</format>
<html>
<valueishtml>0</valueishtml>
</html>
<name>table_name_t</name>
<name>table_no</name>
<visible>1</visible>
<EditStyle style="edit">
<limit>0</limit>
<case>any</case>
<focusrectangle>no</focusrectangle>
<autoselect>yes</autoselect>
<autohscroll>yes</autohscroll>
<imemode>0</imemode>
</EditStyle>
<font>
<face>Arial</face>
<face>Times New Roman</face>
<height>-10</height>
<weight>400</weight>
<family>2</family>
<family>1</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
<background>
<mode>1</mode>
<color>536870912</color>
<mode>2</mode>
<color>79741120</color>
</background>
</TextObject>
</ColumnObject>
<ColumnObject>
<band>Detail</band>
<id>2</id>
<id>3</id>
<alignment>0</alignment>
<tabsequence>10</tabsequence>
<tabsequence>20</tabsequence>
<border>5</border>
<color>33554432</color>
<x>429</x>
<y>16</y>
<color>0</color>
<x>116</x>
<y>50</y>
<height>19</height>
<width>200</width>
<width>479</width>
<format>[general]</format>
<html>
<valueishtml>0</valueishtml>
</html>
<name>table_name</name>
<name>prim_key</name>
<visible>1</visible>
<EditStyle style="edit">
<limit>30</limit>
<limit>100</limit>
<case>any</case>
<focusrectangle>no</focusrectangle>
<autoselect>yes</autoselect>
......@@ -387,38 +601,149 @@
<imemode>0</imemode>
</EditStyle>
<font>
<face>Arial</face>
<face>Times New Roman</face>
<height>-10</height>
<weight>400</weight>
<family>2</family>
<family>1</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
<background>
<mode>1</mode>
<color>536870912</color>
<mode>2</mode>
<color>16777215</color>
</background>
</ColumnObject>
<ColumnObject>
<band>Detail</band>
<id>4</id>
<alignment>0</alignment>
<tabsequence>30</tabsequence>
<border>5</border>
<color>0</color>
<x>116</x>
<y>75</y>
<height>284</height>
<width>479</width>
<format>[general]</format>
<html>
<valueishtml>0</valueishtml>
</html>
<name>sqlselect</name>
<visible>1</visible>
<EditStyle style="edit">
<limit>4000</limit>
<case>any</case>
<focusrectangle>no</focusrectangle>
<autoselect>yes</autoselect>
<autovscroll>yes</autovscroll>
<imemode>0</imemode>
<vscrollbar>yes</vscrollbar>
</EditStyle>
<font>
<face>Times New Roman</face>
<height>-10</height>
<weight>400</weight>
<family>1</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
<background>
<mode>2</mode>
<color>16777215</color>
</background>
</ColumnObject>
<ColumnObject>
<band>Detail</band>
<id>6</id>
<alignment>0</alignment>
<tabsequence>50</tabsequence>
<border>5</border>
<color>0</color>
<x>116</x>
<y>394</y>
<height>37</height>
<width>479</width>
<format>[general]</format>
<html>
<valueishtml>0</valueishtml>
</html>
<name>where_cond</name>
<visible>1</visible>
<EditStyle style="edit">
<limit>0</limit>
<case>any</case>
<autoselect>yes</autoselect>
<imemode>0</imemode>
</EditStyle>
<font>
<face>Times New Roman</face>
<height>-10</height>
<weight>400</weight>
<family>1</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
<background>
<mode>2</mode>
<color>16777215</color>
</background>
</ColumnObject>
<ColumnObject>
<band>Detail</band>
<id>10</id>
<alignment>0</alignment>
<tabsequence>60</tabsequence>
<border>5</border>
<color>0</color>
<x>116</x>
<y>440</y>
<height>16</height>
<width>99</width>
<format>[general]</format>
<html>
<valueishtml>0</valueishtml>
</html>
<name>sql_flag</name>
<visible>1</visible>
<EditStyle style="ddlb">
<limit>0</limit>
<allowedit>no</allowedit>
<case>any</case>
<imemode>0</imemode>
</EditStyle>
<font>
<face>Times New Roman</face>
<height>-10</height>
<weight>400</weight>
<family>1</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
<background>
<mode>2</mode>
<color>16777215</color>
</background>
</ColumnObject>
<TextObject>
<band>Detail</band>
<alignment>1</alignment>
<text>Confirm Condition:</text>
<text>Table No:</text>
<border>0</border>
<color>33554432</color>
<x>12</x>
<y>195</y>
<color>0</color>
<x>11</x>
<y>22</y>
<height>16</height>
<width>127</width>
<width>101</width>
<html>
<valueishtml>0</valueishtml>
</html>
<name>confirm_condition_t</name>
<name>table_no_t</name>
<visible>1</visible>
<font>
<face>Arial</face>
<face>Times New Roman</face>
<height>-10</height>
<weight>400</weight>
<family>2</family>
<family>1</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
......@@ -430,23 +755,23 @@
<TextObject>
<band>Detail</band>
<alignment>1</alignment>
<text>Where Cond:</text>
<text>Primary Key:</text>
<border>0</border>
<color>33554432</color>
<x>33</x>
<y>221</y>
<color>0</color>
<x>28</x>
<y>50</y>
<height>16</height>
<width>106</width>
<width>84</width>
<html>
<valueishtml>0</valueishtml>
</html>
<name>where_cond_t</name>
<name>prim_key_t</name>
<visible>1</visible>
<font>
<face>Arial</face>
<face>Times New Roman</face>
<height>-10</height>
<weight>400</weight>
<family>2</family>
<family>1</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
......@@ -458,23 +783,23 @@
<TextObject>
<band>Detail</band>
<alignment>1</alignment>
<text>Delete Flag:</text>
<text>Sqlselect:</text>
<border>0</border>
<color>33554432</color>
<x>32</x>
<y>278</y>
<height>22</height>
<width>106</width>
<color>0</color>
<x>10</x>
<y>75</y>
<height>15</height>
<width>101</width>
<html>
<valueishtml>0</valueishtml>
</html>
<name>sql_flag_t</name>
<name>sqlselect_t</name>
<visible>1</visible>
<font>
<face>Arial</face>
<face>Times New Roman</face>
<height>-10</height>
<weight>400</weight>
<family>2</family>
<family>1</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
......@@ -483,34 +808,26 @@
<color>536870912</color>
</background>
</TextObject>
<ColumnObject>
<TextObject>
<band>Detail</band>
<id>7</id>
<alignment>0</alignment>
<tabsequence>60</tabsequence>
<border>5</border>
<color>33554432</color>
<x>147</x>
<y>280</y>
<height>19</height>
<width>180</width>
<format>[general]</format>
<alignment>1</alignment>
<text>Confirm Condition:</text>
<border>0</border>
<color>0</color>
<x>11</x>
<y>366</y>
<height>16</height>
<width>101</width>
<html>
<valueishtml>0</valueishtml>
</html>
<name>sql_flag</name>
<name>confirm_condition_t</name>
<visible>1</visible>
<EditStyle style="ddlb">
<limit>0</limit>
<allowedit>no</allowedit>
<case>any</case>
<imemode>0</imemode>
</EditStyle>
<font>
<face>Arial</face>
<face>Times New Roman</face>
<height>-10</height>
<weight>400</weight>
<family>2</family>
<family>1</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
......@@ -518,81 +835,125 @@
<mode>1</mode>
<color>536870912</color>
</background>
</ColumnObject>
<ColumnObject>
</TextObject>
<TextObject>
<band>Detail</band>
<id>6</id>
<alignment>0</alignment>
<tabsequence>50</tabsequence>
<border>5</border>
<color>33554432</color>
<x>147</x>
<y>221</y>
<height>51</height>
<width>484</width>
<format>[general]</format>
<text>Where Condition :</text>
<border>0</border>
<color>0</color>
<x>13</x>
<y>396</y>
<height>16</height>
<width>99</width>
<html>
<valueishtml>0</valueishtml>
</html>
<name>where_cond</name>
<name>where_cond_t</name>
<visible>1</visible>
<EditStyle style="edit">
<limit>500</limit>
<case>any</case>
<focusrectangle>no</focusrectangle>
<autoselect>yes</autoselect>
<autohscroll>yes</autohscroll>
<imemode>0</imemode>
</EditStyle>
<font>
<face>Arial</face>
<face>Times New Roman</face>
<height>-10</height>
<weight>400</weight>
<family>2</family>
<family>1</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
<background>
<mode>1</mode>
<color>536870912</color>
<mode>2</mode>
<color>79741120</color>
</background>
</ColumnObject>
</TextObject>
<TextObject>
<band>Detail</band>
<alignment>0</alignment>
<text>Delete Flag :</text>
<border>0</border>
<color>0</color>
<x>14</x>
<y>441</y>
<height>16</height>
<width>99</width>
<html>
<valueishtml>0</valueishtml>
</html>
<name>sql_flag_t</name>
<visible>1</visible>
<font>
<face>Times New Roman</face>
<height>-10</height>
<weight>400</weight>
<family>1</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
<background>
<mode>2</mode>
<color>79741120</color>
</background>
</TextObject>
<TextObject>
<band>Detail</band>
<alignment>0</alignment>
<text>Old Table Name:</text>
<border>0</border>
<color>0</color>
<x>376</x>
<y>440</y>
<height>15</height>
<width>99</width>
<html>
<valueishtml>0</valueishtml>
</html>
<name>table_name_old_t</name>
<visible>0</visible>
<font>
<face>Times New Roman</face>
<height>-10</height>
<weight>400</weight>
<family>1</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
<background>
<mode>2</mode>
<color>79741120</color>
</background>
</TextObject>
<ColumnObject>
<band>Detail</band>
<id>5</id>
<id>11</id>
<alignment>0</alignment>
<tabsequence>40</tabsequence>
<border>5</border>
<color>33554432</color>
<x>147</x>
<y>194</y>
<height>19</height>
<width>483</width>
<tabsequence>70</tabsequence>
<border>0</border>
<color>0</color>
<x>479</x>
<y>440</y>
<height>15</height>
<width>90</width>
<format>[general]</format>
<html>
<valueishtml>0</valueishtml>
</html>
<name>confirm_condition</name>
<visible>1</visible>
<name>table_name_old</name>
<visible>0</visible>
<EditStyle style="edit">
<limit>300</limit>
<limit>0</limit>
<case>any</case>
<focusrectangle>no</focusrectangle>
<autoselect>yes</autoselect>
<autohscroll>yes</autohscroll>
<imemode>0</imemode>
</EditStyle>
<font>
<face>Arial</face>
<face>Times New Roman</face>
<height>-10</height>
<weight>400</weight>
<family>2</family>
<family>1</family>
<pitch>2</pitch>
<charset>0</charset>
</font>
<background>
<mode>1</mode>
<color>536870912</color>
<mode>2</mode>
<color>16777215</color>
</background>
</ColumnObject>
<HtmlTable>
......
......@@ -369,8 +369,16 @@ public class AttdMonIC extends ValidatorEJB
break;
}
else if(workDays.length() > 0)
{
try
{
workDay = Double.parseDouble(workDays);
}
catch(Exception e)
{
errCode = genericUtility.getErrorString("work_days", "VTMONATD11", userId);
break;
}
if(workDay < 0)
{
errCode = genericUtility.getErrorString("work_days", "VTMONATD04", userId);
......@@ -387,8 +395,16 @@ public class AttdMonIC extends ValidatorEJB
break;
}
else if(woffDays.length() > 0)
{
try
{
woffDay = Double.parseDouble(woffDays);
}
catch(Exception e)
{
errCode = genericUtility.getErrorString("woff_days", "VTMONATD12", userId);
break;
}
if(woffDay < 0)
{
errCode = genericUtility.getErrorString("woff_days", "VTMONATD06", userId);
......@@ -405,8 +421,16 @@ public class AttdMonIC extends ValidatorEJB
break;
}
if(lvesTaken.length() > 0)
{
try
{
lveTaken = Double.parseDouble(lvesTaken);
}
catch(Exception e)
{
errCode = genericUtility.getErrorString("lves_taken", "VTMONATD13", userId);
break;
}
if(lveTaken < 0)
{
errCode = genericUtility.getErrorString("lves_taken", "VTMONATD08", userId);
......@@ -521,7 +545,7 @@ public class AttdMonIC extends ValidatorEJB
try
{
con = getConnection();
String sql="",empCode="",empFname="",empLname="",status="",prdCode="";
String sql="",empCode="",empFname="",empLname="",status="",prdCode="",errCode="";
Date reliveDate = null,dateJoin=null;
String workDays="",woffDays="",lvesTaken="",withHeld="";
double workDayCnt=0,woffDaysCnt=0,lvesTakenCnt=0;
......@@ -529,7 +553,7 @@ public class AttdMonIC extends ValidatorEJB
{
currentFormNo = Integer.parseInt(objContext);
}
String userId = getValueFromXTRA_PARAMS(xtraParams,"loginCode");
logInEmpCode = getValueFromXTRA_PARAMS(xtraParams, "loginEmpCode");
loginSite = getValueFromXTRA_PARAMS(xtraParams, "loginSiteCode");
SimpleDateFormat sdfApplFormat = new SimpleDateFormat(genericUtility.getApplDateFormat());
......@@ -559,7 +583,7 @@ public class AttdMonIC extends ValidatorEJB
if("emp_code".equalsIgnoreCase(currentColumn))
{
empCode = E12GenericUtility.checkNull(genericUtility.getColumnValue("emp_code", dom));
sql="select emp_lname, emp_fname, date_join, relieve_date, status from employee where emp_code=?";
sql="select emp_lname, emp_fname, date_join, relieve_date, status,with_held from employee where emp_code=?";
pStmt = con.prepareStatement(sql);
pStmt.setString(1, empCode);
rs = pStmt.executeQuery();
......@@ -570,6 +594,7 @@ public class AttdMonIC extends ValidatorEJB
dateJoin = rs.getDate("date_join");
reliveDate = rs.getDate("relieve_date");
status = E12GenericUtility.checkNull(rs.getString("status"));
withHeld = E12GenericUtility.checkNull(rs.getString("with_held"));
}
if(rs!=null)
{
......@@ -583,6 +608,7 @@ public class AttdMonIC extends ValidatorEJB
}
valueXmlString.append("<emp_lname><![CDATA[").append(empLname).append("]]></emp_lname>");
valueXmlString.append("<emp_fname><![CDATA[").append(empFname).append("]]></emp_fname>");
valueXmlString.append("<with_held><![CDATA[").append(withHeld).append("]]></with_held>");
if(dateJoin!=null)
{
valueXmlString.append("<date_join><![CDATA[").append(sdfApplFormat.format(dateJoin)).append("]]></date_join>");
......@@ -606,17 +632,39 @@ public class AttdMonIC extends ValidatorEJB
valueXmlString.append("<work_days><![CDATA[").append(workDayCnt).append("]]></work_days>");
}
else
{
try
{
workDayCnt = Double.parseDouble(workDays);
}
catch(Exception e)
{
errCode = genericUtility.getErrorString("", "VTMONATD11", userId);
valueXmlString.append(errCode);
valueXmlString.append("</Detail1>\r\n");
valueXmlString.append("</Root>\r\n");
break;
}
}
if(woffDays.length() <= 0)
{
woffDaysCnt = 0;
valueXmlString.append("<woff_days><![CDATA[").append(woffDaysCnt).append("]]></woff_days>");
}
else
{
try
{
woffDaysCnt = Double.parseDouble(woffDays);
}
catch(Exception e)
{
errCode = genericUtility.getErrorString("", "VTMONATD13", userId);
valueXmlString.append(errCode);
valueXmlString.append("</Detail1>\r\n");
valueXmlString.append("</Root>\r\n");
break;
}
workDayCnt =workDayCnt+woffDaysCnt;
}
if(lvesTaken.length() <= 0)
......@@ -625,8 +673,19 @@ public class AttdMonIC extends ValidatorEJB
valueXmlString.append("<lves_taken><![CDATA[").append(woffDaysCnt).append("]]></lves_taken>");
}
else
{
try
{
lvesTakenCnt = Double.parseDouble(lvesTaken);
}
catch(Exception e)
{
errCode = genericUtility.getErrorString("", "VTMONATD12", userId);
valueXmlString.append(errCode);
valueXmlString.append("</Detail1>\r\n");
valueXmlString.append("</Root>\r\n");
break;
}
workDayCnt = workDayCnt+lvesTakenCnt;
}
if(withHeld.equalsIgnoreCase("Y"))
......
package ibase.webitm.ejb.adm;
import java.rmi.RemoteException;
import java.sql.Connection;
import java.sql.PreparedStatement;
import java.sql.ResultSet;
import java.text.SimpleDateFormat;
import java.util.Date;
import org.w3c.dom.Document;
import org.w3c.dom.Node;
import org.w3c.dom.NodeList;
import ibase.utility.BaseLogger;
import ibase.utility.E12GenericUtility;
import ibase.webitm.ejb.ITMDBAccessEJB;
import ibase.webitm.ejb.ValidatorEJB;
import ibase.webitm.utility.ITMException;
public class EmpTransferSqlIc extends ValidatorEJB
{
E12GenericUtility genericUtility = new E12GenericUtility();
public String wfValData(String xmlString, String xmlString1, String xmlString2, String objContext, String editFlag, String xtraParams) throws RemoteException,ITMException
{
Document dom = null;
Document dom1 = null;
Document dom2 = null;
String errString = "";
try
{
if(xmlString != null && xmlString.trim().length() > 0)
{
dom = genericUtility.parseString(xmlString);
}
if(xmlString1 != null && xmlString1.trim().length() > 0)
{
dom1 = genericUtility.parseString(xmlString1);
}
if(xmlString2 != null && xmlString2.trim().length() > 0)
{
dom2 = genericUtility.parseString(xmlString2);
}
errString = wfValData(dom,dom1,dom2,objContext,editFlag,xtraParams);
}
catch(Exception e)
{
BaseLogger.log("0", null, null, "Exception EmpTransferSqlIc : [wfValData(S)] " + e.getMessage());
errString = genericUtility.createErrorString(e);
e.printStackTrace();
throw new ITMException(e);
}
return errString;
}
public String wfValData(Document dom, Document dom1, Document dom2,String objContext, String editFlag, String xtraParams) throws RemoteException,ITMException
{
NodeList parentNodeList = null , childNodeList = null;
Node parentNode = null , childNode = null;
String childNodeName = "" , errCode = "", userId = "";
Connection conn = null;
PreparedStatement pStmt = null;
ResultSet rs = null;
ITMDBAccessEJB itmdbAccessEJB = new ITMDBAccessEJB();
int currentFormNo = 0, childNodeListLen = 0 , columnCtr = 0 , rowCnt = 0;
try
{
conn = getConnection();
if(objContext != null && objContext.trim().length()>0)
{
currentFormNo = Integer.parseInt(objContext);
}
String whereCondition = "", tableName = "", confirmCondition = "" , sql = "", loginSite = "", maxEmpCode = "", sqlSelect = "", tableNo = "";
loginSite = getValueFromXTRA_PARAMS(xtraParams, "loginSiteCode");
userId = getValueFromXTRA_PARAMS(xtraParams, "loginCode");
switch(currentFormNo)
{
case 1:
parentNodeList = dom.getElementsByTagName("Detail1");
int parentNodeListLen = parentNodeList.getLength();
for(columnCtr = 0;columnCtr < parentNodeListLen;columnCtr++)
{
parentNode = parentNodeList.item(columnCtr);
childNodeList = parentNode.getChildNodes();
childNodeListLen = childNodeList.getLength();
for(rowCnt = 0; rowCnt < childNodeListLen ; rowCnt++)
{
childNode = childNodeList.item(rowCnt);
childNodeName = childNode.getNodeName();
BaseLogger.log("3", null , null , "chilNodeNameSP:"+childNodeName);
if("table_name".equalsIgnoreCase(childNodeName))
{
int count = 0;
String tableNames = "";
tableName = E12GenericUtility.checkNull(genericUtility.getColumnValue("table_name", dom));
tableNo = E12GenericUtility.checkNull(genericUtility.getColumnValue("table_no", dom));
sql ="select table_name from emptransfersql where table_no = ?";
pStmt = conn.prepareStatement(sql);
pStmt.setString(1, tableNo);
rs = pStmt.executeQuery();
while(rs.next())
{
tableNames = rs.getString("table_name");
}
if(rs != null)
{
rs.close();
rs = null;
}
if(pStmt != null)
{
pStmt.close();
pStmt = null;
}
if(tableName.length() == 0)
{
//errCode = itmdbAccessEJB.getErrorString("table_name", "VTTABNULL", userId);
errCode = itmdbAccessEJB.getErrorString("table_name", "VTTABNULL", userId, "", conn);
break;
}
sql = "select count(1) from emptransfersql where table_name = ?";
pStmt = conn.prepareStatement(sql);
pStmt.setString(1, tableName);
rs = pStmt.executeQuery();
while(rs.next())
{
count = rs.getInt(1);
BaseLogger.log("3", null , null , "count:"+count);
}
if(rs != null)
{
rs.close();
rs = null;
}
if(pStmt != null)
{
pStmt.close();
pStmt = null;
}
if((count > 0) && (!tableName.equalsIgnoreCase(tableNames)))
{
BaseLogger.log("3", null , null , "Inside the error"+tableNames);
errCode = itmdbAccessEJB.getErrorString("table_name", "VTTABNAME", userId, "", conn);
break;
}
}
else if("sqlselect".equalsIgnoreCase(childNodeName))
{
sqlSelect = E12GenericUtility.checkNull(genericUtility.getColumnValue("sqlselect", dom));
try
{
sqlSelect = sqlSelect + " where 1 =?";
pStmt = conn.prepareStatement(sqlSelect);
pStmt.setString(1, "2");
rs = pStmt.executeQuery();
if(rs != null)
{
rs.close();
rs = null;
}
if(pStmt != null)
{
pStmt.close();
pStmt = null;
}
}
catch(Exception e)
{
errCode = itmdbAccessEJB.getErrorString("table_name", "VTSQLSELE", userId, "", conn);
}
}
else if("where_cond".equalsIgnoreCase(childNodeName))
{
tableName = E12GenericUtility.checkNull(genericUtility.getColumnValue("table_name", dom));
whereCondition = E12GenericUtility.checkNull(genericUtility.getColumnValue("where_cond", dom));
if(whereCondition != null)
{
sql= "select count(1) from "+ tableName +" "+whereCondition;
sql = "select max(emp_code) as empCode from employee where work_site = ?";
pStmt = conn.prepareStatement(sql);
pStmt.setString( 1 , loginSite);
rs = pStmt.executeQuery();
while(rs.next())
{
maxEmpCode = rs.getString("empCode");
}
if(rs != null)
{
rs.close();
rs = null;
}
if(pStmt != null)
{
pStmt.close();
pStmt = null;
}
if(maxEmpCode.length() <= 0)
{
errCode = itmdbAccessEJB.getErrorString("table_name", "VTWHERECON", userId, "", conn);
}
}
}
else if("confirm_condition".equalsIgnoreCase(childNodeName))
{
tableName = E12GenericUtility.checkNull(genericUtility.getColumnValue("table_name", dom));
whereCondition = E12GenericUtility.checkNull(genericUtility.getColumnValue("where_cond", dom));
confirmCondition = E12GenericUtility.checkNull(genericUtility.getColumnValue("confirm_condition", dom));
if(whereCondition.length() != 0)
{
if(confirmCondition.length() != 0)
{
sql = "select count(*) from "+tableName+""+whereCondition+"and "+confirmCondition;
sql = "select max(emp_code) as empCode from employee where work_site = ?";
pStmt = conn.prepareStatement(sql);
pStmt.setString( 1 , loginSite);
rs = pStmt.executeQuery();
while(rs.next())
{
maxEmpCode = rs.getString("empCode");
}
if(rs != null)
{
rs.close();
rs = null;
}
if(pStmt != null)
{
pStmt.close();
pStmt = null;
}
if(maxEmpCode.length() <= 0)
{
errCode = itmdbAccessEJB.getErrorString("table_name", "VTWHERECON", userId, "", conn);
break;
}
}
}
else
{
errCode = itmdbAccessEJB.getErrorString("table_name", "VTWHERECLA", userId, "", conn);
break;
}
}
}
}
}
}
catch(Exception e)
{
BaseLogger.log("0", null, null, "Exception EmptransferSqlIc: [wfValData(S)] " + e.getMessage());
}
finally
{
try
{
if(rs != null)
{
rs.close();
rs = null;
}
if(pStmt != null)
{
pStmt.close();
pStmt = null;
}
if(conn != null)
{
conn.close();
conn = null;
}
}
catch(Exception e)
{
BaseLogger.log("0", null, null, "Exception EmpTransferSqlIc : [wfValData(S)] " + e.getMessage());
}
}
return errCode;
}
public String itemChanged(String xmlString, String xmlStringHdr, String xmlStringAll, String objContext, String currentColumn, String editFlag, String xtraParams) throws RemoteException,ITMException
{
Document dom = null, domHdr = null, domAll = null;
String valueXmlString = "";
try
{
if (xmlString != null && xmlString.trim().length() > 0)
{
System.out.println("xmlString:"+xmlString);
dom = genericUtility.parseString(xmlString);
}
if (xmlStringHdr != null && xmlStringHdr.trim().length() > 0)
{
domHdr = genericUtility.parseString(xmlStringHdr);
}
if (xmlStringAll != null && xmlStringAll.trim().length() > 0)
{
domAll = genericUtility.parseString(xmlStringAll);
}
valueXmlString = itemChanged(dom, domHdr, domAll, objContext, currentColumn, editFlag, xtraParams);
}
catch (Exception e)
{
BaseLogger.log("0", null, null, "Exception EmpTransferSqlIc: [itemChanged(S)] " + e.getMessage());
throw new ITMException(e);
}
return valueXmlString;
}
public String itemChanged(Document dom, Document domHdr , Document domAll ,String objContext,String currentColumn, String editFlag ,String xtraParams) throws RemoteException
{
StringBuffer valueXmlString = new StringBuffer();
Connection con = null;
PreparedStatement pStmt = null;
ResultSet rs = null;
int currentFormNo=0;
try
{
con = getConnection();
SimpleDateFormat sdfApplFormat = new SimpleDateFormat(genericUtility.getApplDateFormat());
if(objContext!=null)
{
currentFormNo = Integer.parseInt(objContext);
}
String tableName="",primaryKey="",sqlSelect="",sql="";
valueXmlString = new StringBuffer("<?xml version=\"1.0\" encoding=''?>\r\n<Root>\r\n<header>\r\n<editFlag>");
valueXmlString.append(editFlag).append("</editFlag>\r\n</header>\r\n");
switch(currentFormNo)
{
case 1:
valueXmlString.append("<Detail1>\r\n");
if("itm_default".equalsIgnoreCase(currentColumn))
{
String loginCode=getValueFromXTRA_PARAMS(xtraParams,"loginCode");
String chgTerm=getValueFromXTRA_PARAMS( xtraParams, "chgTerm" );
Date currentDate = new Date();
valueXmlString.append( "<chg_date><![CDATA[" ).append(sdfApplFormat.format(currentDate).toString()).append( "]]></chg_date>\r\n" );
valueXmlString.append( "<chg_user><![CDATA[" ).append(loginCode).append( "]]></chg_user >\r\n" );
valueXmlString.append( "<chg_term><![CDATA[" ).append(chgTerm).append( "]]></chg_term>\r\n" );
if("A".equalsIgnoreCase(editFlag))
{
valueXmlString.append( "<table_name_old><![CDATA[" ).append("").append( "]]></table_name_old>\r\n" );
}
}
else if("table_name".equalsIgnoreCase(currentColumn))
{
tableName = E12GenericUtility.checkNull(genericUtility.getColumnValue("table_name", dom));
System.out.println("tableName:"+tableName);
sql = "select ddf_create_prim(?) as primarykey from dual";
pStmt = con.prepareStatement(sql);
pStmt.setString(1, tableName);
rs = pStmt.executeQuery();
while(rs.next())
{
primaryKey = rs.getString("primarykey");
}
if(rs!=null)
{
rs.close();
rs = null;
}
if(pStmt!=null)
{
pStmt.close();
pStmt = null;
}
sql="select ddf_create_select(?) as selectTable from dual";
pStmt = con.prepareStatement(sql);
pStmt.setString(1, tableName);
rs = pStmt.executeQuery();
while(rs.next())
{
sqlSelect = rs.getString("selectTable");
}
if(rs!=null)
{
rs.close();
rs = null;
}
if(pStmt!=null)
{
pStmt.close();
pStmt = null;
}
valueXmlString.append("<prim_key><![CDATA[").append(primaryKey).append("]]></prim_key>");
valueXmlString.append("<sqlselect><![CDATA[").append(sqlSelect).append("]]></sqlselect>");
valueXmlString.append( "<table_name_old><![CDATA[" ).append(tableName).append( "]]></table_name_old>\r\n" );
}
valueXmlString.append("</Detail1>\r\n");
valueXmlString.append("</Root>\r\n");
}
}
catch(Exception e)
{
BaseLogger.log("0", null, null, "Exception EmpTransferSqlIc : [itemChanged(S)] " + e.getMessage());
}
finally
{
try
{
if(rs != null)
{
rs.close();
rs = null;
}
if(pStmt != null)
{
pStmt.close();
pStmt = null;
}
if(con != null)
{
con.close();
con = null;
}
}
catch(Exception e)
{
BaseLogger.log("0", null, null, "Exception EmpTransferSqlIc : [itemChanged(S)] " + e.getMessage());
}
}
return valueXmlString.toString();
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment