SELECT * FROM bode_orcom WHERE oc_region2 IN (2) and oc_swdespacho='1' and  oc_guiafecha='0000-00-00' and (oc_origen is null or oc_origen = '')
SELECT * FROM bode_detoc WHERE doc_oc_id IN (17063) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(17063)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (43102)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104100)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (17064) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(17064)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (43100)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104127)

====================================================================================

SELECT * FROM bode_orcom WHERE oc_region2 IN (7) and oc_swdespacho='1' and  oc_guiafecha='0000-00-00' and (oc_origen is null or oc_origen = '')
SELECT * FROM bode_detoc WHERE doc_oc_id IN (15390) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(15390)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (15391) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(15391)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (15394) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(15394)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (15399) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(15399)

====================================================================================

SELECT * FROM bode_orcom WHERE oc_region2 IN (8) and oc_swdespacho='1' and  oc_guiafecha='0000-00-00' and (oc_origen is null or oc_origen = '')
SELECT * FROM bode_detoc WHERE doc_oc_id IN (15712) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(15712)

====================================================================================

SELECT * FROM bode_orcom WHERE oc_region2 IN (9) and oc_swdespacho='1' and  oc_guiafecha='0000-00-00' and (oc_origen is null or oc_origen = '')
SELECT * FROM bode_detoc WHERE doc_oc_id IN (15594) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(15594)

====================================================================================

SELECT * FROM bode_orcom WHERE oc_region2 IN (21) and oc_swdespacho='1' and  oc_guiafecha='0000-00-00' and (oc_origen is null or oc_origen = '')
SELECT * FROM bode_detoc WHERE doc_oc_id IN (10534) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(10534)

====================================================================================

SELECT * FROM bode_orcom WHERE oc_region2 IN (24) and oc_swdespacho='1' and  oc_guiafecha='0000-00-00' and (oc_origen is null or oc_origen = '')
SELECT * FROM bode_detoc WHERE doc_oc_id IN (15521) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(15521)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (15524) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(15524)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (15579) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(15579)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (15588) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(15588)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (15590) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(15590)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (15593) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(15593)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (15595) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(15595)

====================================================================================

SELECT * FROM bode_orcom WHERE oc_region2 IN (25) and oc_swdespacho='1' and  oc_guiafecha='0000-00-00' and (oc_origen is null or oc_origen = '')
SELECT * FROM bode_detoc WHERE doc_oc_id IN (15352) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(15352)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (15363) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(15363)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (15499) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(15499)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (15515) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(15515)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (15518) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(15518)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (15538) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(15538)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (15541) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(15541)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (15603) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(15603)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (15606) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(15606)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (15607) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(15607)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (15608) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(15608)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (15610) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(15610)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (15613) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(15613)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (15621) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(15621)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (15622) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(15622)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (15628) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(15628)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (15631) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(15631)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (15634) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(15634)

====================================================================================

SELECT * FROM bode_orcom WHERE oc_region2 IN (26) and oc_swdespacho='1' and  oc_guiafecha='0000-00-00' and (oc_origen is null or oc_origen = '')
SELECT * FROM bode_detoc WHERE doc_oc_id IN (15587) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(15587)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (15638) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(15638)

====================================================================================

SELECT * FROM bode_orcom WHERE oc_region2 IN (27) and oc_swdespacho='1' and  oc_guiafecha='0000-00-00' and (oc_origen is null or oc_origen = '')
SELECT * FROM bode_detoc WHERE doc_oc_id IN (15537) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(15537)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1250 WHERE ding_id IN (39970)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (96576)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (15635) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(15635)

====================================================================================

SELECT * FROM bode_orcom WHERE oc_region2 IN (31) and oc_swdespacho='1' and  oc_guiafecha='0000-00-00' and (oc_origen is null or oc_origen = '')
SELECT * FROM bode_detoc WHERE doc_oc_id IN (15912) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(15912)

====================================================================================

SELECT * FROM bode_orcom WHERE oc_region2 IN (33) and oc_swdespacho='1' and  oc_guiafecha='0000-00-00' and (oc_origen is null or oc_origen = '')
SELECT * FROM bode_detoc WHERE doc_oc_id IN (16789) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(16789)

====================================================================================

SELECT * FROM bode_orcom WHERE oc_region2 IN (35) and oc_swdespacho='1' and  oc_guiafecha='0000-00-00' and (oc_origen is null or oc_origen = '')
SELECT * FROM bode_detoc WHERE doc_oc_id IN (16447) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(16447)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (16448) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(16448)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (16449) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(16449)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (16450) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(16450)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (16451) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(16451)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (16452) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(16452)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (16454) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(16454)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (16455) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(16455)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (16521) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(16521)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (16522) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(16522)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (16523) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(16523)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (16524) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(16524)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (16525) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(16525)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (16526) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(16526)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (16527) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(16527)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (16529) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(16529)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (16530) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(16530)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (16531) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(16531)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (16532) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(16532)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (16533) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(16533)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (16534) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(16534)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (16535) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(16535)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (16536) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(16536)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (16537) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(16537)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (16541) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(16541)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (16542) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(16542)

====================================================================================

SELECT * FROM bode_orcom WHERE oc_region2 IN (37) and oc_swdespacho='1' and  oc_guiafecha='0000-00-00' and (oc_origen is null or oc_origen = '')
SELECT * FROM bode_detoc WHERE doc_oc_id IN (5839) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(5839)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (6454) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(6454)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (6455) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(6455)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (9959) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(9959)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (9961) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(9961)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (9962) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(9962)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (12114) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(12114)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (12542) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(12542)

====================================================================================

SELECT * FROM bode_orcom WHERE oc_region2 IN (48) and oc_swdespacho='1' and  oc_guiafecha='0000-00-00' and (oc_origen is null or oc_origen = '')
SELECT * FROM bode_detoc WHERE doc_oc_id IN (12811) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(12811)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 16 WHERE ding_id IN (35012)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (79709)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 4 WHERE ding_id IN (34993)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (79710)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 4 WHERE ding_id IN (34992)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (79711)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (34998)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (79712)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (35013)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (79715)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 3 WHERE ding_id IN (35009)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (79716)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 3 WHERE ding_id IN (34997)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (79717)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (35020)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (79718)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 5 WHERE ding_id IN (34961)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (79719)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (13020) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(13020)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 16 WHERE ding_id IN (35012)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (81584)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 3 WHERE ding_id IN (34993)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (81585)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 3 WHERE ding_id IN (35013)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (81586)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 3 WHERE ding_id IN (35003)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (81587)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 3 WHERE ding_id IN (35014)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (81590)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 3 WHERE ding_id IN (35019)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (81592)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 3 WHERE ding_id IN (35009)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (81593)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (34996)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (81595)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (35002)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (81597)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 3 WHERE ding_id IN (35001)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (81599)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (35020)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (81600)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (34976)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (81601)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (13034) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(13034)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 4 WHERE ding_id IN (34989)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (81635)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 100 WHERE ding_id IN (34984)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (81636)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (34985)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (81637)

====================================================================================

SELECT * FROM bode_orcom WHERE oc_region2 IN (49) and oc_swdespacho='1' and  oc_guiafecha='0000-00-00' and (oc_origen is null or oc_origen = '')
SELECT * FROM bode_detoc WHERE doc_oc_id IN (17110) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(17110)

====================================================================================

SELECT * FROM bode_orcom WHERE oc_region2 IN (55) and oc_swdespacho='1' and  oc_guiafecha='0000-00-00' and (oc_origen is null or oc_origen = '')
SELECT * FROM bode_detoc WHERE doc_oc_id IN (15809) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(15809)

====================================================================================

SELECT * FROM bode_orcom WHERE oc_region2 IN (63) and oc_swdespacho='1' and  oc_guiafecha='0000-00-00' and (oc_origen is null or oc_origen = '')
SELECT * FROM bode_detoc WHERE doc_oc_id IN (16816) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(16816)

====================================================================================

SELECT * FROM bode_orcom WHERE oc_region2 IN (64) and oc_swdespacho='1' and  oc_guiafecha='0000-00-00' and (oc_origen is null or oc_origen = '')
SELECT * FROM bode_detoc WHERE doc_oc_id IN (17097) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(17097)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 6 WHERE ding_id IN (36601)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104308)

====================================================================================

SELECT * FROM bode_orcom WHERE oc_region2 IN (70) and oc_swdespacho='1' and  oc_guiafecha='0000-00-00' and (oc_origen is null or oc_origen = '')
SELECT * FROM bode_detoc WHERE doc_oc_id IN (14523) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(14523)

====================================================================================

SELECT * FROM bode_orcom WHERE oc_region2 IN (72) and oc_swdespacho='1' and  oc_guiafecha='0000-00-00' and (oc_origen is null or oc_origen = '')
SELECT * FROM bode_detoc WHERE doc_oc_id IN (14931) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(14931)

====================================================================================

SELECT * FROM bode_orcom WHERE oc_region2 IN (73) and oc_swdespacho='1' and  oc_guiafecha='0000-00-00' and (oc_origen is null or oc_origen = '')
SELECT * FROM bode_detoc WHERE doc_oc_id IN (6060) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(6060)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (7017) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(7017)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 38 WHERE ding_id IN (16404)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (44801)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 18 WHERE ding_id IN (6590)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (44803)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 17 WHERE ding_id IN (4551)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (44804)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 6 WHERE ding_id IN (5568)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (44808)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 15 WHERE ding_id IN (17258)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (44809)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 48 WHERE ding_id IN (16429)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (44810)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 17 WHERE ding_id IN (6598)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (44811)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 42 WHERE ding_id IN (17099)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (44814)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 30000 WHERE ding_id IN (19880)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (44818)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1080 WHERE ding_id IN (12252)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (44819)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 48 WHERE ding_id IN (19559)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (44821)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 3 WHERE ding_id IN (4486)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (44841)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 19 WHERE ding_id IN (2730)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (44842)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 66 WHERE ding_id IN (2728)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (44843)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 21 WHERE ding_id IN (2726)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (44844)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 6 WHERE ding_id IN (2725)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (44845)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 11 WHERE ding_id IN (2721)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (44846)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (8130)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (44848)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (19546)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (44853)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 3350 WHERE ding_id IN (19885)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (44859)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (8649) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(8649)

====================================================================================

SELECT * FROM bode_orcom WHERE oc_region2 IN (76) and oc_swdespacho='1' and  oc_guiafecha='0000-00-00' and (oc_origen is null or oc_origen = '')
SELECT * FROM bode_detoc WHERE doc_oc_id IN (12029) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(12029)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (28829)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (74650)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25819)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (74651)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (12413) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(12413)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (12414) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(12414)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (42248)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102588)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (27368)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102589)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (42254)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102590)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 4 WHERE ding_id IN (31647)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102593)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (28831)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102598)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (25895)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102601)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (25893)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102602)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (25892)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102603)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (25891)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102604)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (25890)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102605)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (25885)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102606)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 12 WHERE ding_id IN (38491)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102643)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (29116)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102644)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 4 WHERE ding_id IN (29117)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102664)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (25913)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102665)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (25887)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102666)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (25884)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102667)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (25882)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102668)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (25881)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102669)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (16859) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(16859)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 6 WHERE ding_id IN (25883)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102457)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (16887) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(16887)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 9 WHERE ding_id IN (25913)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102674)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 9 WHERE ding_id IN (25887)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102675)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 9 WHERE ding_id IN (25884)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102676)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 9 WHERE ding_id IN (25882)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102677)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 9 WHERE ding_id IN (25881)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102678)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 9 WHERE ding_id IN (29116)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102679)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 18 WHERE ding_id IN (29117)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102680)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 8 WHERE ding_id IN (25895)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102682)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 8 WHERE ding_id IN (25893)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102683)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 8 WHERE ding_id IN (25892)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102684)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 8 WHERE ding_id IN (25891)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102685)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 8 WHERE ding_id IN (25890)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102686)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 8 WHERE ding_id IN (25885)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102687)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 48 WHERE ding_id IN (38491)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102689)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 8 WHERE ding_id IN (42248)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102690)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 16 WHERE ding_id IN (25871)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102691)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 14 WHERE ding_id IN (27368)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102692)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 8 WHERE ding_id IN (30881)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102696)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 16 WHERE ding_id IN (31647)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102697)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 4 WHERE ding_id IN (25883)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102701)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 18 WHERE ding_id IN (28830)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102703)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (32709)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102705)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (16902) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(16902)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 24 WHERE ding_id IN (28822)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102740)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 6 WHERE ding_id IN (27368)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102741)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 6 WHERE ding_id IN (32709)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102743)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 6 WHERE ding_id IN (28831)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102744)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 6 WHERE ding_id IN (31647)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102745)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 3 WHERE ding_id IN (42248)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102746)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (25914)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102747)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 3 WHERE ding_id IN (29116)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102748)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 6 WHERE ding_id IN (29117)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102749)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 3 WHERE ding_id IN (25913)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102750)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 3 WHERE ding_id IN (25887)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102751)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 3 WHERE ding_id IN (25884)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102752)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 3 WHERE ding_id IN (25882)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102753)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 3 WHERE ding_id IN (25881)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102754)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (25895)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102755)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (25893)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102756)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (25892)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102757)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (25891)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102758)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (25890)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102759)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (25885)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102760)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 12 WHERE ding_id IN (38491)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102761)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (16904) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(16904)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (29116)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102762)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 4 WHERE ding_id IN (29117)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102763)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (25913)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102764)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (25887)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102765)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (25884)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102766)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (25882)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102767)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (25881)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102768)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (25895)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102772)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (25893)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102773)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (25892)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102774)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (25891)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102775)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (25890)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102776)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 12 WHERE ding_id IN (38491)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102778)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25885)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102779)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (25883)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102781)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 4 WHERE ding_id IN (42255)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102783)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 4 WHERE ding_id IN (32709)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102784)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 4 WHERE ding_id IN (31647)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102785)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 4 WHERE ding_id IN (28831)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102786)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (26688)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102787)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 16 WHERE ding_id IN (36101)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102788)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (27368)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102794)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25914)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102795)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (16920) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(16920)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (36101)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102843)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 6 WHERE ding_id IN (28822)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102844)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (27368)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102845)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (32709)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102846)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (28831)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102847)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (29116)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102848)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (29117)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102861)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25913)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102865)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25887)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102866)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25884)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102867)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25882)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102868)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25881)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102869)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25895)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102870)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25893)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102871)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25892)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102872)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25891)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102873)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25890)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102874)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 6 WHERE ding_id IN (38491)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102876)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25883)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102877)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (26688)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102878)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (31647)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102879)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (16924) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(16924)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (31814)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102880)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 4 WHERE ding_id IN (27368)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102884)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 4 WHERE ding_id IN (31647)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102885)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 4 WHERE ding_id IN (28831)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102886)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 6 WHERE ding_id IN (38491)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102887)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25895)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102888)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25893)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102889)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25892)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102890)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25891)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102891)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25890)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102892)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (25913)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102900)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (25887)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102901)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (25884)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102902)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (25882)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102903)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (25881)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102904)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (29116)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102905)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 4 WHERE ding_id IN (29117)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102906)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (30521)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102912)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (28823)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102932)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (16940) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(16940)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 8 WHERE ding_id IN (27368)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102972)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 9 WHERE ding_id IN (32709)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102980)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 8 WHERE ding_id IN (31647)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102981)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 8 WHERE ding_id IN (28830)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102982)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 5 WHERE ding_id IN (29116)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102983)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 14 WHERE ding_id IN (29117)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102992)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 5 WHERE ding_id IN (25913)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102998)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 5 WHERE ding_id IN (25887)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (102999)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 5 WHERE ding_id IN (25884)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103000)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 5 WHERE ding_id IN (25882)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103001)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 5 WHERE ding_id IN (25881)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103002)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 3 WHERE ding_id IN (25895)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103006)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 3 WHERE ding_id IN (25893)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103007)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 3 WHERE ding_id IN (25892)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103008)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 3 WHERE ding_id IN (25891)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103009)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 3 WHERE ding_id IN (25890)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103010)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (25885)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103011)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 18 WHERE ding_id IN (38491)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103014)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 4 WHERE ding_id IN (31814)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103020)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 4 WHERE ding_id IN (30881)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103028)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 8 WHERE ding_id IN (36101)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103038)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 8 WHERE ding_id IN (25871)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103039)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (32709)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103044)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (16950) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(16950)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 5 WHERE ding_id IN (26688)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103051)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 5 WHERE ding_id IN (29116)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103053)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 10 WHERE ding_id IN (29117)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103054)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 5 WHERE ding_id IN (25913)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103058)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 5 WHERE ding_id IN (25887)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103059)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 5 WHERE ding_id IN (25884)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103060)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 5 WHERE ding_id IN (25882)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103061)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 5 WHERE ding_id IN (25881)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103062)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 3 WHERE ding_id IN (25895)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103082)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 3 WHERE ding_id IN (25893)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103083)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 3 WHERE ding_id IN (25892)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103084)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 3 WHERE ding_id IN (25891)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103085)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 3 WHERE ding_id IN (25890)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103086)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 6 WHERE ding_id IN (38491)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103087)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 10 WHERE ding_id IN (27368)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103095)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (32709)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103101)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 8 WHERE ding_id IN (31647)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103102)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 5 WHERE ding_id IN (25914)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103103)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (25883)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103104)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (25889)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103105)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (25888)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103106)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 8 WHERE ding_id IN (25871)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103107)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (16958) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(16958)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 4 WHERE ding_id IN (27368)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103134)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 4 WHERE ding_id IN (32709)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103140)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (31814)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103143)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (29116)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103146)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 4 WHERE ding_id IN (29117)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103150)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (25913)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103154)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (25889)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103155)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (25888)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103156)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (25887)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103157)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (25884)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103158)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (25883)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103159)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (25882)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103160)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (25881)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103161)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (25895)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103166)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (25893)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103167)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (25892)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103168)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (25891)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103169)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (25890)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103170)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25885)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103171)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 12 WHERE ding_id IN (38491)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103182)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 8 WHERE ding_id IN (42230)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103185)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 8 WHERE ding_id IN (36101)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103186)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (28830)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103188)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (16969) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(16969)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25868)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103240)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (31814)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103241)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (29116)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103244)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (29117)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103246)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25913)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103249)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25887)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103250)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25884)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103251)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25882)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103252)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25881)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103253)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25895)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103255)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25893)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103256)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25892)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103257)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25891)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103258)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25890)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103259)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25885)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103260)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 6 WHERE ding_id IN (38491)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103261)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (27368)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103262)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (31647)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103263)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (28831)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103267)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25889)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103268)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (16973) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(16973)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (42248)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103275)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (31814)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103276)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 3 WHERE ding_id IN (29116)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103280)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 6 WHERE ding_id IN (29117)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103281)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 3 WHERE ding_id IN (25913)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103286)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 3 WHERE ding_id IN (25887)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103287)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 3 WHERE ding_id IN (25882)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103288)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 3 WHERE ding_id IN (25881)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103289)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25895)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103291)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25893)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103292)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25892)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103293)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25891)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103294)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25890)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103295)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 6 WHERE ding_id IN (38491)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103296)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 6 WHERE ding_id IN (27368)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103298)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 6 WHERE ding_id IN (28831)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103301)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 6 WHERE ding_id IN (31647)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103306)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 8 WHERE ding_id IN (25871)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103307)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25914)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103309)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25889)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103311)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25888)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103312)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25883)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103314)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (16974) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(16974)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 6 WHERE ding_id IN (38491)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103319)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25895)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103321)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25893)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103322)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25892)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103323)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25891)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103324)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25890)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103325)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25885)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103326)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25913)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103327)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25887)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103328)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25884)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103329)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25882)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103330)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25881)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103331)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (29116)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103334)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (29117)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103336)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25883)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103339)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 8 WHERE ding_id IN (25869)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103340)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 4 WHERE ding_id IN (26715)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103342)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (32709)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103350)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (26688)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103352)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (16981) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(16981)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (25818)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103359)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (25810)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103360)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (25815)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103362)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 24 WHERE ding_id IN (25819)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103364)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (16982) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(16982)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25788)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103368)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (16983) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(16983)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 8 WHERE ding_id IN (25871)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103906)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (27368)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103937)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (32709)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103941)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (31647)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103942)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (29116)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103944)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (29117)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103947)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25913)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103974)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25895)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103975)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25893)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103976)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25892)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103977)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25891)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103978)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25887)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103979)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25885)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103980)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25884)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103981)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25882)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103982)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25881)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103983)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 6 WHERE ding_id IN (38491)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103985)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25890)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104005)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (17025) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(17025)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25792)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104011)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25790)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104012)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 4 WHERE ding_id IN (26715)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104015)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 8 WHERE ding_id IN (35259)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104021)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (29116)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104025)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (29117)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104026)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25913)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104034)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25887)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104035)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25884)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104036)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25882)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104037)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25881)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104038)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25895)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104050)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25893)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104051)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25892)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104052)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25891)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104053)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25890)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104054)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25885)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104055)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 6 WHERE ding_id IN (38491)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104057)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25798)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104068)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (42248)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104066)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25786)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104069)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25784)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104072)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25802)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104080)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (17038) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(17038)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 3 WHERE ding_id IN (25978)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103814)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 6 WHERE ding_id IN (25970)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103815)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 6 WHERE ding_id IN (25975)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103816)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 6 WHERE ding_id IN (25949)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (103822)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (17053) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(17053)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 8 WHERE ding_id IN (28821)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104119)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (30881)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104120)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (29116)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104121)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25913)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104135)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25887)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104144)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25884)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104145)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25882)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104146)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25881)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104147)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25895)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104152)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25893)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104153)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25892)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104154)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25891)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104155)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25890)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104156)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25885)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104157)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 6 WHERE ding_id IN (38491)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104164)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (26688)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104166)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 4 WHERE ding_id IN (29117)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104174)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (28823)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104175)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (17070) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(17070)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (26688)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104149)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25895)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104158)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25893)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104159)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25892)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104160)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25891)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104161)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25890)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104162)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25887)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104163)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 6 WHERE ding_id IN (38491)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104165)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25913)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104167)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25887)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104168)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25884)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104169)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25882)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104170)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25881)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104171)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (29116)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104172)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (29117)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104173)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (27368)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104176)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (31647)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104177)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (28830)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104178)
SELECT * FROM bode_detoc WHERE doc_oc_id IN (17087) AND doc_estado NOT IN ('ELIMINADO')
UPDATE bode_orcom SET oc_swdespacho = 0 WHERE oc_id IN(17087)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 14 WHERE ding_id IN (29116)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104226)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (29117)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104227)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25913)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104251)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25887)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104252)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25884)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104253)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25882)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104254)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (25881)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104255)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 6 WHERE ding_id IN (25895)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104256)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 6 WHERE ding_id IN (25893)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104257)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 6 WHERE ding_id IN (25892)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104258)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 6 WHERE ding_id IN (25891)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104259)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 6 WHERE ding_id IN (25890)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104260)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 5 WHERE ding_id IN (25885)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104261)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 36 WHERE ding_id IN (38491)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104263)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (42248)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104267)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 10 WHERE ding_id IN (31647)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104274)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 8 WHERE ding_id IN (30881)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104279)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 8 WHERE ding_id IN (36101)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104283)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 24 WHERE ding_id IN (25871)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104284)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 2 WHERE ding_id IN (32709)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104287)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 4 WHERE ding_id IN (28830)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104288)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 4 WHERE ding_id IN (42255)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104289)
UPDATE bode_detingreso SET ding_unidad = ding_unidad + 1 WHERE ding_id IN (27368)
UPDATE bode_detoc SET doc_estado = 'ELIMINADO' WHERE doc_id IN (104290)

====================================================================================

