salix/db/versions/.archive/10186-silverGerbera/04-regularizar_Sticker_Inve...

6 lines
280 B
MySQL
Raw Permalink Normal View History

-- recorrer los inventarios y verificar que no tengan el campo sticker > 0 en caso contrario regularizar a zero
UPDATE vn.buy b
JOIN vn.entry e ON e.id = b.entryFk
JOIN vn.entryConfig ec ON ec.inventorySupplierFk = e.supplierFk
SET printedStickers = 0
WHERE printedStickers <> 0;