This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
select | |
sw.id, | |
count(header.id) as headers, | |
(select count(*) from giscedata_switching_step_info where sw_id = sw.id group by sw_id) as steps | |
from giscedata_switching_step_header header | |
JOIN giscedata_switching sw ON sw.id=header.sw_id | |
group by sw.id | |
having | |
count(header.id) != (select count(*) from giscedata_switching_step_info where sw_id = sw.id group by sw_id); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# begin; | |
# update giscegas_lectures_lectura set lectura = lectura_m3; | |
# update giscegas_lectures_lectura_pool set lectura = lectura_m3; | |
# update giscegas_facturacio_lectures set lect_actual = lect_actual_m3; | |
# update giscegas_facturacio_lectures set lect_anterior = lect_anterior_m3; | |
from tqdm import tqdm | |
from erppeek import Client | |
c = Client("server:8069", "database", "login") | |
lect_obj = c.GiscegasLecturesLectura |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
delete from wkf_workitem where id in (select min(wkd.id) from wkf_workitem wkd where wkd.inst_id in (select | |
inst_id | |
from | |
wkf_workitem wki | |
JOIN wkf_instance ins ON ins.id = wki.inst_id | |
group by | |
inst_id, ins.res_id, ins.res_type, ins.uid | |
having | |
count(*) > 1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sed -i '/Las pólizas/ s//Los contratos/g' $1 | |
sed -i '/las pólizas/ s//los contratos/g' $1 | |
sed -i '/La póliza/ s//El contrato/g' $1 | |
sed -i '/de la póliza/ s//del contrato/g' $1 | |
sed -i '/la póliza/ s//el contrato/g' $1 | |
sed -i '/na póliza/ s//n contrato/g' $1 | |
sed -i '/va póliza/ s//vo contrato/g' $1 | |
sed -i '/Pólizas/ s//Contratos/g' $1 | |
sed -i '/pólizas/ s//contratos/g' $1 | |
sed -i '/Póliza/ s//Contrato/g' $1 |