Caso sincronização está funcionando e a informação redução z for igual tanto na matriz quanto na filial deve executar-se seguintes comandos subsequentes
1-update cupom set grid = grid where nr_serie = 'xxxxx' and data_emissao = 'aaaa-mm-dd';
Onde n_serie é número serie ecf contendo XX********* onde xx são letras e * são numeros ex: bematech BR111111 , Daruma DR222222
2-
update cupom_pagto set grid = grid where cupom in (select grid from cupom where nr_serie = 'BE091110100011280376' and data_emissao = '2017-05-10');
3-
update cupom_produto set grid = grid where cupom in (select grid from cupom where nr_serie = 'BE091110100011280376' and data_emissao = '2017-05-10');
4-
update cupom_total set grid = grid where cupom in (select grid from cupom where nr_serie = 'BE091110100011280376' and data_emissao = '2017-05-10');
5-
update cupom_nao_fiscal set grid = grid where nr_serie = 'BE091110100011280376' and data_movto = '2017-05-10';
Tabela
*
cupom_produto
cupom_total
cupom
*
reducao_z
Cupom/Reducao_z
update tabela set grid=grid where data_movto='aaaa-mm-dd';
cupom_total/cupom_produto
update tabela set grid=grid where cupom in (select grid from cupom where data_movto ='aaaa-mm-dd');