20191223 - remote pc tapanuli - kirim data dpa tapanuli ke catat meter - sukses 20191227 - tutup bendel dari web cater - download data cust dari taput (11413) - hapus data cust dari oracle (11570) - update tdil = - insert di t_lang (11413) 20200103 - mulai pencatatan cater(pak jepri tanya) 20200106 - ganti imei hp An.Lindocun Simanjuntak karena rusak 20200121 - petugas (surti) tidak melakukan tutup bendel sehingga data tidak dapat di kirim => ubah apicontroller upad img dan data 20200203 - tutup bendel - upload dpa - ada masalah : kesalah pahaman karena data periode 202001 belum tutup bendel sehingga tidak bisa di upload dpa. sedangkan petugas baca meter sudah melakukan download data dan pencatatan berdasarkan data periode 202001 sehingga foto asli tereplace dengan foto yang baru 20200205 - buka source code yang mengamankan proses kirim data anroid di blth aktif 20200206 - update stand dan pemakaian di periode 202002 20200226 - remote pc tapanuli untuk proses kirim billing (kirim data dari catat meter ke billing tapanuli) {"total":11413,"waktu":6.964698366324106} 20200302 - upload DPA dari billing tapanuli 20200303 - update rek air ke tlang 20200306 - ubah imei petugas karena hp rusak - ubah prosedur kirim karena ada petugas yang tidak melakukan proses tutup bendel 20200326 -kirim data ke billing jumlah 11380 20200401 - ambil data dari billing ke cater jumlah 11352 20200409 - update rek air ke tlang 20200422 - kirim data ke billing total 4603 waktu 7.1736936489741 20200504 - Ambil data dari billing ke cater jumlah 11335 20200505 - update rek air ke tlang 20200520 - kirim data ke billing total 11335 waktu 9.52869501511256 20200603 - Ambil data dari billing ke cater jumlah 11345 20200608 ##Update Pemakaian## - update rek air ke tlang (11365) ->merge into t_lang a using (select * from rekair where periode = '202005' and statrek ='A' )b on (trim(a.nolang) =trim(b.nosamw)) when matched then update set a.st1 = b.met_k, a.pem1= b.pakai > Affected rows: 11343 > Time: 0.185s update t_lang set pem = st-st1 where tgl is not null and st<>0 and st1<>0 > Affected rows: 363 > Time: 0.013s 20200624 - kirim data ke billing 20200701 ##Trasnfer data tapanuli-sby (Download DPA) Cek table t_lang sudah empty blm jika belum.. sarankan utk tutup bendel via web Remote PC : select * from cust where stat_smb=30 and post=1 --data 11324 Server PDAM : -> copy replace data to server table cust -> "insert into t_dil (nolang,subzone,lokasi,urut,haribaca,jenis_plg,status_plg,nama,alamat,kd_tarip,status) select nosamw,substr(nosamw,1,4),substr(nosamw,1,4)||'00','999','1',"jlw","urjlwp","nama","alamat","jlw","stat_smb" from cust where nosamw not in (select nolang from t_dil)" --13 row insert -> insert ke t_lang "insert into t_lang (nolang,zone,subzone,lokasi,urut,haribaca,jenis_plg,nama,alamat,kdtarip,st1,pem1,blth,kelompok) select a.nolang,'0',a.subzone,a.lokasi,a.urut,a.haribaca,a.jenis_plg,a.nama,a.alamat,a.kd_tarip,nvl(b.st,'0'),nvl(b.pem,'0'),'202007',1 from t_dil a left join t_histori b on a.nolang=b.nolang and b.blth='202006' where a.nolang in (select nosamw from cust)" --data 11324 20200703 (#update pemakaian) ->remote select * from rekair where periode='202006' 11338 row ->Server ->Import file to rekair 11338 row merge into t_lang a using (select * from rekair where periode = '202006' and statrek ='A') b on (trim(a.nolang) = trim(b.nosamw)) when matched then update set a.st1 = b.met_k, a.pem1= b.pakai > Affected rows: 11324 > Time: 0.221s update t_lang set pem = st-st1 where tgl is not null and st<>0 and st1<>0 > Affected rows: 376 > Time: 0.013s 20200727 (Kirim data ke Billing) nyalakan xamppp di pc itu jalankan url http://localhost/abms/public/kirimbiling {"total":11324,"waktu":10.034823950131734} 20200803 ##Transfer data tapanuli-sby (Download DPA) select * from t_lang -> Cek table t_lang sudah empty blm jika belum.. sarankan utk tutup bendel via web Remote PC : select * from cust where stat_smb=30 and post=1 --data 11334 -->export sql-> cust_20200803.sql Server PDAM : -> truncate (empty) and Insert data to server table cust -> truncate table cust -> Execute Sql File -> "insert into t_dil (nolang,subzone,lokasi,urut,haribaca,jenis_plg,status_plg,nama,alamat,kd_tarip,status) select nosamw,substr(nosamw,1,4),substr(nosamw,1,4)||'00','999','1',"jlw","urjlwp","nama","alamat","jlw","stat_smb" from cust where nosamw not in (select nolang from t_dil)" --43 row insert -> insert ke t_lang "insert into t_lang (nolang,zone,subzone,lokasi,urut,haribaca,jenis_plg,nama,alamat,kdtarip,st1,pem1,blth,kelompok) select a.nolang,'0',a.subzone,a.lokasi,a.urut,a.haribaca,a.jenis_plg,a.nama,a.alamat,a.kd_tarip,nvl(b.st,'0'),nvl(b.pem,'0'),'202008',1 from t_dil a left join t_histori b on a.nolang=b.nolang and b.blth='202007' where a.nolang in (select nosamw from cust)" --data 11334 inserted 20200806 (#update pemakaian Terakhir-Penyesuaian stand meter akhir) ->remote select * from rekair where periode='202007' 11347 row ->Server ->Import file to rekair 11347 row merge into t_lang a using (select * from rekair where periode = '202007' and statrek ='A') b on (trim(a.nolang) = trim(b.nosamw)) when matched then update set a.st1 = b.met_k, a.pem1= b.pakai > Affected rows: 11344 > Time: 0.221s update t_lang set pem = st-st1 where tgl is not null and st<>0 and st1<>0 > Affected rows: 131 > Time: 0.013s 20200826 (Kirim data ke Billing) nyalakan xamppp di pc itu jalankan url http://localhost/abms/public/kirimbiling 20200902 ##Transfer data tapanuli-sby (Download DPA) select * from t_lang -> Cek table t_lang sudah empty blm jika belum.. sarankan utk tutup bendel via web Remote PC : select * from cust where stat_smb=30 and post=1 --data 11625 -->export sql-> cust_20200902.sql Server PDAM : -> truncate (empty) and Insert data to server table cust -> truncate table cust -> Execute Sql File -> "insert into t_dil (nolang,subzone,lokasi,urut,haribaca,jenis_plg,status_plg,nama,alamat,kd_tarip,status) select nosamw,substr(nosamw,1,4),substr(nosamw,1,4)||'00','999','1',"jlw","urjlwp","nama","alamat","jlw","stat_smb" from cust where nosamw not in (select nolang from t_dil)" --Affected rows: 308 -> insert ke t_lang "insert into t_lang (nolang,zone,subzone,lokasi,urut,haribaca,jenis_plg,nama,alamat,kdtarip,st1,pem1,blth,kelompok) select a.nolang,'0',a.subzone,a.lokasi,a.urut,a.haribaca,a.jenis_plg,a.nama,a.alamat,a.kd_tarip,nvl(b.st,'0'),nvl(b.pem,'0'),'202009',1 from t_dil a left join t_histori b on a.nolang=b.nolang and b.blth='202008' where a.nolang in (select nosamw from cust)" --Affected rows: 11625 20200904 (#update pemakaian Terakhir-Penyesuaian stand meter akhir) ->remote select * from rekair where periode='202008' 11627 row ->Server ->Import file to rekair 11627 row merge into t_lang a using (select * from rekair where periode = '202008' and statrek ='A') b on (trim(a.nolang) = trim(b.nosamw)) when matched then update set a.st1 = b.met_k, a.pem1= b.pakai > Affected rows: 11624 > Time: 0.198s update t_lang set pem = st-st1 where tgl is not null and st<>0 and st1<>0 > Affected rows: 19 > Time: 0.007s 20200925 (--Rollback Tutup periode (blth=202009 kelompok=1): INSERT INTO t_lang SELECT * FROM t_histori WHERE blth='202009' AND kelompok='1'; DELETE FROM t_histori WHERE blth='202009' AND kelompok='1'; DELETE FROM log_closeperiode WHERE thbl='202009' AND periode='1'; 20200925 (Kirim data ke Billing) nyalakan xamppp di pc itu jalankan url http://localhost/abms/public/kirimbiling {"total":11625,"waktu":7.342119932174683} 20200905 ##Transfer data tapanuli-sby (Download DPA) select * from t_lang -> Cek table t_lang sudah empty blm jika belum.. sarankan utk tutup bendel via web Remote PC : select * from cust where stat_smb=30 and post=1 --data 12358 -->export sql-> cust_20201005.sql Server PDAM : -> truncate (empty) and Insert data to server table cust -> truncate table cust -> Execute Sql File -> "insert into t_dil (nolang,subzone,lokasi,urut,haribaca,jenis_plg,status_plg,nama,alamat,kd_tarip,status) select nosamw,substr(nosamw,1,4),substr(nosamw,1,4)||'00','999','1',"jlw","urjlwp","nama","alamat","jlw","stat_smb" from cust where nosamw not in (select nolang from t_dil)" --Affected rows: 746 -> insert ke t_lang "insert into t_lang (nolang,zone,subzone,lokasi,urut,haribaca,jenis_plg,nama,alamat,kdtarip,st1,pem1,blth,kelompok) select a.nolang,'0',a.subzone,a.lokasi,a.urut,a.haribaca,a.jenis_plg,a.nama,a.alamat,a.kd_tarip,nvl(b.st,'0'),nvl(b.pem,'0'),'202010',1 from t_dil a left join t_histori b on a.nolang=b.nolang and b.blth='202009' where a.nolang in (select nosamw from cust)" --Affected rows: 12358 20201008 (#update pemakaian Terakhir-Penyesuaian stand meter akhir) ->remote select * from rekair where periode='202009' 12358 row ->Server ->Import file to rekair 12358 row merge into t_lang a using (select * from rekair where periode = '202009' and statrek ='A') b on (trim(a.nolang) = trim(b.nosamw)) when matched then update set a.st1 = b.met_k, a.pem1= b.pakai > Affected rows: 12356 > Time: 1.814s update t_lang set pem = st-st1 where tgl is not null and st<>0 and st1<>0 > Affected rows: 579 > Time: 0.014s 20201026 (Kirim data ke Billing) nyalakan xamppp di pc itu jalankan url http://localhost/abms/public/kirimbiling {"total":12358,"waktu":8.752100582917532} --- Loss --- 20201126 (Kirim data ke Billing) nyalakan xamppp di pc itu jalankan url http://localhost/abms/public/kirimbiling {"total":9851,"waktu":8.922576999664306} 20201130 ##Transfer data tapanuli-sby (Download DPA) select * from t_lang -> Cek table t_lang sudah empty blm jika belum.. sarankan utk tutup bendel via web Remote PC : select * from cust where stat_smb=30 and post=1 --data 12359 -->export sql-> cust_20201130.sql Server PDAM : -> truncate (empty) and Insert data to server table cust -> truncate table cust -> Execute Sql File -> "insert into t_dil (nolang,subzone,lokasi,urut,haribaca,jenis_plg,status_plg,nama,alamat,kd_tarip,status) select nosamw,substr(nosamw,1,4),substr(nosamw,1,4)||'00','999','1',"jlw","urjlwp","nama","alamat","jlw","stat_smb" from cust where nosamw not in (select nolang from t_dil)" --Affected rows: 5 -> insert ke t_lang "insert into t_lang (nolang,zone,subzone,lokasi,urut,haribaca,jenis_plg,nama,alamat,kdtarip,st1,pem1,blth,kelompok) select a.nolang,'0',a.subzone,a.lokasi,a.urut,a.haribaca,a.jenis_plg,a.nama,a.alamat,a.kd_tarip,nvl(b.st,'0'),nvl(b.pem,'0'),'202012',1 from t_dil a left join t_histori b on a.nolang=b.nolang and b.blth='202011' where a.nolang in (select nosamw from cust)" --Affected rows: 12359 20201112 (#update pemakaian Terakhir-Penyesuaian stand meter akhir) ->remote select * from rekair where periode='202011' 12376 row ->Server ->Import file to rekair 12376 row merge into t_lang a using (select * from rekair where periode = '202011' and statrek ='A') b on (trim(a.nolang) = trim(b.nosamw)) when matched then update set a.st1 = b.met_k, a.pem1= b.pakai > Affected rows: 12345 > Time: 1.814s update t_lang set pem = st-st1 where tgl is not null and st<>0 and st1<>0 > Affected rows: 166 > Time: 0.014s 20201222 (Kirim data ke Billing) nyalakan xamppp di pc itu jalankan url http://localhost/abms/public/kirimbiling {"total":12359,"waktu":9.048734215895335} //================================================= 2021 ==================================================== 20210104 ##Transfer data tapanuli-sby (Download DPA) select * from t_lang -> Cek table t_lang sudah empty blm jika belum.. sarankan utk tutup bendel via web Remote PC : select * from cust where stat_smb=30 and post=1 --data 12241 -->export sql-> cust_20210104.sql Server PDAM : -> truncate (empty) and Insert data to server table cust -> truncate table cust -> Execute Sql File -> "insert into t_dil (nolang,subzone,lokasi,urut,haribaca,jenis_plg,status_plg,nama,alamat,kd_tarip,status) select nosamw,substr(nosamw,1,4),substr(nosamw,1,4)||'00','999','1',"jlw","urjlwp","nama","alamat","jlw","stat_smb" from cust where nosamw not in (select nolang from t_dil)" --Affected rows: 54 -> insert ke t_lang "insert into t_lang (nolang,zone,subzone,lokasi,urut,haribaca,jenis_plg,nama,alamat,kdtarip,st1,pem1,blth,kelompok) select a.nolang,'0',a.subzone,a.lokasi,a.urut,a.haribaca,a.jenis_plg,a.nama,a.alamat,a.kd_tarip,nvl(b.st,'0'),nvl(b.pem,'0'),'202101',1 from t_dil a left join t_histori b on a.nolang=b.nolang and b.blth='202012' where a.nolang in (select nosamw from cust)" --Affected rows: 12241 ## 20210108 ##(#update pemakaian Terakhir-Penyesuaian stand meter akhir) ->remote select * from rekair where periode='202012' 12240 row ->Server ->Import file to rekair 12240 row merge into t_lang a using (select * from rekair where periode = '202012' and statrek ='A') b on (trim(a.nolang) = trim(b.nosamw)) when matched then update set a.st1 = b.met_k, a.pem1= b.pakai > Affected rows: 12233 > Time: 0,265s update t_lang set pem = st-st1 where tgl is not null and st<>0 and st1<>0 > Affected rows: 168 > Time: 0,015s 20210127 (Kirim data ke Billing) nyalakan xamppp di pc itu jalankan url http://localhost/abms/public/kirimbiling {"total":12241,"waktu":8.518120535214742} ## 20210201 ##Transfer data tapanuli-sby (Download DPA) select * from t_lang -> Cek table t_lang sudah empty blm jika belum.. sarankan utk tutup bendel via web Remote PC : select * from cust where stat_smb=30 and post=1 --data 12248 -->export sql-> cust_20210201.sql Server PDAM : -> truncate (empty) and Insert data to server table cust -> truncate table cust -> Execute Sql File -> "insert into t_dil (nolang,subzone,lokasi,urut,haribaca,jenis_plg,status_plg,nama,alamat,kd_tarip,status) select nosamw,substr(nosamw,1,4),substr(nosamw,1,4)||'00','999','1',"jlw","urjlwp","nama","alamat","jlw","stat_smb" from cust where nosamw not in (select nolang from t_dil)" --Affected rows: 13 -> insert ke t_lang "insert into t_lang (nolang,zone,subzone,lokasi,urut,haribaca,jenis_plg,nama,alamat,kdtarip,st1,pem1,blth,kelompok) select a.nolang,'0',a.subzone,a.lokasi,a.urut,a.haribaca,a.jenis_plg,a.nama,a.alamat,a.kd_tarip,nvl(b.st,'0'),nvl(b.pem,'0'),'202102',1 from t_dil a left join t_histori b on a.nolang=b.nolang and b.blth='202101' where a.nolang in (select nosamw from cust)" --Affected rows: 12248 ## 20210203 ##(#update pemakaian Terakhir-Penyesuaian stand meter akhir) ->remote select * from rekair where periode='202101' 12260 row ->Server ->Import file to rekair 12260 row merge into t_lang a using (select * from rekair where periode = '202101' and statrek ='A') b on (trim(a.nolang) = trim(b.nosamw)) when matched then update set a.st1 = b.met_k, a.pem1= b.pakai > Affected rows: 12247 > Time: 0,265s update t_lang set pem = st-st1 where tgl is not null and st<>0 and st1<>0 > Affected rows: 204 > Time: 0,015s ## 2021024 (Kirim data ke Billing) nyalakan xamppp di pc itu jalankan url http://localhost/abms/public/kirimbiling _{"total":12248,"waktu":8.518120535214742} ## 20210301 ##Transfer data tapanuli-sby (Download DPA) select * from t_lang -> Cek table t_lang sudah empty blm jika belum.. sarankan utk tutup bendel via web Remote PC : select * from cust where stat_smb=30 and post=1 --data 12072 -->export sql-> cust_20210301.sql Server PDAM : -> truncate (empty) and Insert data to server table cust -> truncate table cust -> Execute Sql File MERGE INTO t_dil a USING ( SELECT * FROM cust ) b ON( trim(a.nolang) = trim(b.nosamw)) WHEN MATCHED THEN UPDATE SET a.nolang = b.nosamw, a.subzone = substr(b.nosamw,1,4), a.lokasi = substr(b.nosamw,1,4)||'00', a.urut = '999', a.haribaca = '1', a.jenis_plg = b."jlw", a.status_plg= b."urjlwp", a.nama = b."nama", a.alamat = b."alamat", a.kd_tarip = b."jlw", a.status = b."stat_smb" ; -> "insert into t_dil (nolang,subzone,lokasi,urut,haribaca,jenis_plg,status_plg,nama,alamat,kd_tarip,status) select nosamw,substr(nosamw,1,4),substr(nosamw,1,4)||'00','999','1',"jlw","urjlwp","nama","alamat","jlw","stat_smb" from cust where nosamw not in (select nolang from t_dil)" --Affected rows: 46 -> insert ke t_lang "insert into t_lang (nolang,zone,subzone,lokasi,urut,haribaca,jenis_plg,nama,alamat,kdtarip,st1,pem1,blth,kelompok) select a.nolang,'0',a.subzone,a.lokasi,a.urut,a.haribaca,a.jenis_plg,a.nama,a.alamat,a.kd_tarip,nvl(b.st,'0'),nvl(b.pem,'0'),'202103',1 from t_dil a left join t_histori b on a.nolang=b.nolang and b.blth='202102' where a.nolang in (select nosamw from cust)" --Affected rows: 12072 ## 20210303 ##(#update pemakaian Terakhir-Penyesuaian stand meter akhir) ->remote select * from rekair where periode='202102' 12073 row ->Server ->Import file to rekair 12073 row merge into t_lang a using (select * from rekair where periode = '202102' and statrek ='A') b on (trim(a.nolang) = trim(b.nosamw)) when matched then update set a.st1 = b.met_k, a.pem1= b.pakai > Affected rows: 12072 update t_lang set pem = st-st1 where tgl is not null and st<>0 and st1<>0 > Affected rows: 252 ## 20210319 ## Penyesuaian Data PLG Baru MERGE INTO t_lang a USING ( SELECT * FROM t_dil ) b ON( trim(a.nolang) = trim(b.nolang)) WHEN MATCHED THEN UPDATE SET a.nolang = b.nolang, a.zone = '0', a.subzone = b.subzone a.lokasi = b.lokasi a.urut = b.urut a.haribaca = b.haribaca a.jenis_plg = b.jenis_plg, a.nama = b.nama, a.alamat = b.alamat, a.kdtarip = b.kd_tarip ; ## 20210329 ## Kirim data ke Billing nyalakan xamppp di pc itu jalankan url http://localhost/abms/public/kirimbiling {"total":1000,"waktu":2.160373564561208,"page":5,"last_page":49} {"total":10250,"waktu":15.200219400723775,"page":46,"last_page":49} {"total":822,"waktu":7.862799715995789} total all : 12.072 ## 20210406 ##Transfer data tapanuli-sby (Download DPA) select * from t_lang -> Cek table t_lang sudah empty blm jika belum.. sarankan utk tutup bendel via web Remote PC : select * from cust where stat_smb=30 and post=1 --data 12122 -->export sql-> cust_20210406.sql Server PDAM : -> truncate (empty) and Insert data to server table cust -> truncate table cust -> Execute Sql File MERGE INTO t_dil a USING ( SELECT * FROM cust ) b ON( trim(a.nolang) = trim(b.nosamw)) WHEN MATCHED THEN UPDATE SET a.subzone = substr(b.nosamw,1,4), a.lokasi = substr(b.nosamw,1,4)||'00', a.urut = '999', a.haribaca = '1', a.jenis_plg = b."jlw", a.status_plg= b."urjlwp", a.nama = b."nama", a.alamat = b."alamat", a.kd_tarip = b."jlw", a.status = b."stat_smb" ; Affected rows: 12048 -> "insert into t_dil (nolang,subzone,lokasi,urut,haribaca,jenis_plg,status_plg,nama,alamat,kd_tarip,status) select nosamw,substr(nosamw,1,4),substr(nosamw,1,4)||'00','999','1',"jlw","urjlwp","nama","alamat","jlw","stat_smb" from cust where nosamw not in (select nolang from t_dil)" --Affected rows: 74 -> insert ke t_lang "insert into t_lang (nolang,zone,subzone,lokasi,urut,haribaca,jenis_plg,nama,alamat,kdtarip,st1,pem1,blth,kelompok) select a.nolang,'0',a.subzone,a.lokasi,a.urut,a.haribaca,a.jenis_plg,a.nama,a.alamat,a.kd_tarip,nvl(b.st,'0'),nvl(b.pem,'0'),'202104',1 from t_dil a left join t_histori b on a.nolang=b.nolang and b.blth='202103' where a.nolang in (select nosamw from cust)" --Affected rows: 12122 ## 20210408 ##(#update pemakaian Terakhir-Penyesuaian stand meter akhir) ->remote select * from rekair where periode='202103' 12126 row ->Server ->Import file to rekair 12126 row merge into t_lang a using (select * from rekair where periode = '202103' and statrek ='A') b on (trim(a.nolang) = trim(b.nosamw)) when matched then update set a.st1 = b.met_k, a.pem1= b.pakai > Affected rows: 12121 update t_lang set pem = st-st1 where tgl is not null and st<>0 and st1<>0 > Affected rows: 267 ## 20210427 ## Kirim data ke Billing nyalakan xamppp di pc itu jalankan url http://localhost/abms/public/kirimbiling {"total":12122,"waktu":10.304939417044322,"page":49,"last_page":49} total all : 12122 ## 20210503 ##Transfer data tapanuli-sby (Download DPA) select * from t_lang -> Cek table t_lang sudah empty blm jika belum.. sarankan utk tutup bendel via web Remote PC : select * from cust where stat_smb=30 and post=1 --data 12094 -->export sql-> cust_20210503.sql Server PDAM : -> truncate (empty) and Insert data to server table cust -> truncate table cust -> Execute Sql File MERGE INTO t_dil a USING ( SELECT * FROM cust ) b ON( trim(a.nolang) = trim(b.nosamw)) WHEN MATCHED THEN UPDATE SET a.subzone = substr(b.nosamw,1,4), a.lokasi = substr(b.nosamw,1,4)||'00', a.urut = '999', a.haribaca = '1', a.jenis_plg = b."jlw", a.status_plg= b."urjlwp", a.nama = b."nama", a.alamat = b."alamat", a.kd_tarip = b."jlw", a.status = b."stat_smb" ; Affected rows: 12079 -> "insert into t_dil (nolang,subzone,lokasi,urut,haribaca,jenis_plg,status_plg,nama,alamat,kd_tarip,status) select nosamw,substr(nosamw,1,4),substr(nosamw,1,4)||'00','999','1',"jlw","urjlwp","nama","alamat","jlw","stat_smb" from cust where nosamw not in (select nolang from t_dil)" --Affected rows: 15 -> insert ke t_lang "insert into t_lang (nolang,zone,subzone,lokasi,urut,haribaca,jenis_plg,nama,alamat,kdtarip,st1,pem1,blth,kelompok) select a.nolang,'0',a.subzone,a.lokasi,a.urut,a.haribaca,a.jenis_plg,a.nama,a.alamat,a.kd_tarip,nvl(b.st,'0'),nvl(b.pem,'0'),'202105',1 from t_dil a left join t_histori b on a.nolang=b.nolang and b.blth='202104' where a.nolang in (select nosamw from cust)" --Affected rows: 12094 ## 20210508 ##(#update pemakaian Terakhir-Penyesuaian stand meter akhir) ->remote select * from rekair where periode='202104' 12100 row ->sql file ( replace ` ) ->Server ->Import file to rekair 12100 row merge into t_lang a using (select * from rekair where periode = '202104' and statrek ='A') b on (trim(a.nolang) = trim(b.nosamw)) when matched then update set a.st1 = b.met_k, a.pem1= b.pakai > Affected rows: 12094 update t_lang set pem = st-st1 where tgl is not null and st<>0 and st1<>0 > Affected rows: 180 ## 20210528 ## Kirim data ke Billing nyalakan xamppp di pc itu jalankan url http://localhost/abms/public/kirimbiling {"total":11094,"waktu":7.490095082918803,"page":49,"last_page":49} total all : 12122 ## 20210503 ##Transfer data tapanuli-sby (Download DPA) select * from t_lang -> Cek table t_lang sudah empty blm jika belum.. sarankan utk tutup bendel via web Remote PC : select * from cust where stat_smb=30 and post=1 --data 12099 -->export sql-> cust_20210603.sql Server PDAM : -> truncate (empty) and Insert data to server table cust -> truncate table cust -> Execute Sql File MERGE INTO t_dil a USING ( SELECT * FROM cust ) b ON( trim(a.nolang) = trim(b.nosamw)) WHEN MATCHED THEN UPDATE SET a.subzone = substr(b.nosamw,1,4), a.lokasi = substr(b.nosamw,1,4)||'00', a.urut = '999', a.haribaca = '1', a.jenis_plg = b."jlw", a.status_plg= b."urjlwp", a.nama = b."nama", a.alamat = b."alamat", a.kd_tarip = b."jlw", a.status = b."stat_smb" ; Affected rows: 12085 -> "insert into t_dil (nolang,subzone,lokasi,urut,haribaca,jenis_plg,status_plg,nama,alamat,kd_tarip,status) select nosamw,substr(nosamw,1,4),substr(nosamw,1,4)||'00','999','1',"jlw","urjlwp","nama","alamat","jlw","stat_smb" from cust where nosamw not in (select nolang from t_dil)" --Affected rows: 14 -> insert ke t_lang "insert into t_lang (nolang,zone,subzone,lokasi,urut,haribaca,jenis_plg,nama,alamat,kdtarip,st1,pem1,blth,kelompok) select a.nolang,'0',a.subzone,a.lokasi,a.urut,a.haribaca,a.jenis_plg,a.nama,a.alamat,a.kd_tarip,nvl(b.st,'0'),nvl(b.pem,'0'),'202106',1 from t_dil a left join t_histori b on a.nolang=b.nolang and b.blth='202105' where a.nolang in (select nosamw from cust)" --Affected rows: 12099 ## 20210608 ##(#update pemakaian Terakhir-Penyesuaian stand meter akhir) ->remote select * from rekair where periode='202105' 12106 row ->sql file ( replace ` ) ->Server ->Import file to rekair 12106 row merge into t_lang a using (select * from rekair where periode = '202105' and statrek ='A') b on (trim(a.nolang) = trim(b.nosamw)) when matched then update set a.st1 = b.met_k, a.pem1= b.pakai > Affected rows: 12099 update t_lang set pem = st-st1 where tgl is not null and st<>0 and st1<>0 > Affected rows: 293 ## 20210628 ## Kirim data ke Billing nyalakan xamppp di pc itu jalankan url http://localhost/abms/public/kirimbiling {"total":7750,"waktu":7.100110002358755,"page":32,"last_page":49} {"total":4349,"waktu":8.542455267906188,"page":49,"last_page":49} total all :7750+4349= 12.099 ## 20210701 ##Transfer data tapanuli-sby (Download DPA) select * from t_lang -> Cek table t_lang sudah empty blm jika belum.. sarankan utk tutup bendel via web Remote PC : select * from cust where stat_smb=30 and post=1 --data 12114 -->export sql-> cust_20210701.sql change ' => " , "cust" => cust , "nosamw" => nosamw Server PDAM : -> truncate (empty) and Insert data to server table cust -> truncate table cust -> Execute Sql File MERGE INTO t_dil a USING ( SELECT * FROM cust ) b ON( trim(a.nolang) = trim(b.nosamw)) WHEN MATCHED THEN UPDATE SET a.subzone = substr(b.nosamw,1,4), a.lokasi = substr(b.nosamw,1,4)||'00', a.urut = '999', a.haribaca = '1', a.jenis_plg = b."jlw", a.status_plg= b."urjlwp", a.nama = b."nama", a.alamat = b."alamat", a.kd_tarip = b."jlw", a.status = b."stat_smb" ; Affected rows: 12088 -> insert ke t_dil insert into t_dil (nolang,subzone,lokasi,urut,haribaca,jenis_plg,status_plg,nama,alamat,kd_tarip,status) select nosamw,substr(nosamw,1,4),substr(nosamw,1,4)||'00','999','1',"jlw","urjlwp","nama","alamat","jlw","stat_smb" from cust where nosamw not in (select nolang from t_dil) --Affected rows: 26 -> insert ke t_lang insert into t_lang (nolang,zone,subzone,lokasi,urut,haribaca,jenis_plg,nama,alamat,kdtarip,st1,pem1,blth,kelompok) select a.nolang,'0',a.subzone,a.lokasi,a.urut,a.haribaca,a.jenis_plg,a.nama,a.alamat,a.kd_tarip,nvl(b.st,'0'),nvl(b.pem,'0'),'202107',1 from t_dil a left join t_histori b on a.nolang=b.nolang and b.blth='202106' where a.nolang in (select nosamw from cust) --Affected rows: 12114 ## 20210705 ##(#update pemakaian Terakhir-Penyesuaian stand meter akhir) ->remote select * from rekair where periode='202106' 12116 row ->sql file ( replace ` ) ->Server ->Import file to rekair 12116 row merge into t_lang a using (select * from rekair where periode = '202106' and statrek ='A') b on (trim(a.nolang) = trim(b.nosamw)) when matched then update set a.st1 = b.met_k, a.pem1= b.pakai > Affected rows: 12114 update t_lang set pem = st-st1 where tgl is not null and st<>0 and st1<>0 > Affected rows: 6 ##