Customize Consent Preferences

We use cookies to help you navigate efficiently and perform certain functions. You will find detailed information about all cookies under each consent category below.

The cookies that are categorized as "Necessary" are stored on your browser as they are essential for enabling the basic functionalities of the site. ... 

Always Active

Necessary cookies are required to enable the basic features of this site, such as providing secure log-in or adjusting your consent preferences. These cookies do not store any personally identifiable data.

Functional cookies help perform certain functionalities like sharing the content of the website on social media platforms, collecting feedback, and other third-party features.

Analytical cookies are used to understand how visitors interact with the website. These cookies help provide information on metrics such as the number of visitors, bounce rate, traffic source, etc.

Performance cookies are used to understand and analyze the key performance indexes of the website which helps in delivering a better user experience for the visitors.

Advertisement cookies are used to provide visitors with customized advertisements based on the pages you visited previously and to analyze the effectiveness of the ad campaigns.

Portal Info

Focado no bem-estar, capacitação e evolução da performance dos nossos times.

E-trade

COMANDOS


 

ALTERAÇÃO DAS NOTAS DE REGIME NORMAL PARA SIMPLES

UPDATE MOVIMENTO_PRODUTO SET CSOSN=ICMS_CST, ICMS_CST=0 WHERE CSOSN=0 AND ICMS_CST>0

 

AUMENTAR TAMANHO DE ESPAÇO NO LOG

ALTER DATABASE ETrade SET RECOVERY SIMPLE;
DBCC SHRINKFILE(ETrade_log, 40);
ALTER DATABASE ETrade MODIFY FILE (NAME = ETrade_log, SIZE = 45MB, FILEGROWTH = 1MB, MAXSIZE = 9000MB);
ALTER DATABASE ETrade SET RECOVERY FULL

 

AUMENTA LOG SEM LIMITE

ALTER DATABASE ETrade SET RECOVERY SIMPLE;DBCC SHRINKFILE(ETrade_log, 100)

 

VERSÃO USADA NO BANCO

SELECT @@VERSION

 

ERRO DE IDE NÃO INFORMADO DO PRODUTO

update Estoque_Atual set Produto__Ide = p.ide
from Estoque_Atual ea join produto p on ea.produto = p.codigo

 

CORREÇÃO NFC-E COM REJEIÇÃO 564

update Movimento_Produto set Valor_Total = Qtde*Valor_Unit, valor_Final = Valor_Total – Desc_Valor WHERE movimento__ide in (Select Ide from movimento where sequencia in (Sequencias aqui separadas por virgula))

 

CORREÇÃO NFC-E COM REJEIÇÃO 629

update Movimento_Produto set Qtde = Valor_Total/Valor_Unit where Movimento__Ide = (select ide from Movimento where Sequencia = ‘SEQUENCIA AQUI’)

 

CORREÇÃO NFC-E COM REJEIÇÃO 217

UPDATE Movimento_NFe set Codigo_Status = ‘100’ WHERE Movimento__Ide IN(select ide from Movimento where Sequencia IN(12345 , 123456 , 1234567 ) )

 

AJUSTA MOVIMENTAÇÃO

update Movimento_Produto set CSOSN = ‘X’ from movimento_produto as mp inner join movimento as m on mp.movimento__ide = m.ide where mp.CSOSN = ‘103’ and m.sequencia in (730,729,719,718,714,713) Só vai alterar o CSOSN = ‘X’ pro que você for usar Troca só o X, mantém as aspas simples

 

REMOVE NFCE DO MOVIMENTO – Permite lançar venda novamente

update movimento set NFCe_Identificador = ‘00000000-0000-0000-0000-000000000000’ where Sequencia IN(coloque as sequencias separadas por virgula )

 

REMOVE NFE DO MOVIMENTO – Permite lançar venda novamente

UPDATE MOVIMENTO SET NFe_Identificador = ‘00000000-0000-0000-0000-000000000000’,
Data_Alteracao = getdate()
WHERE Sequencia IN(sequencia do movimento) and Filial__Codigo = 1

Não confundir sequencia do movimento com número da nota

 

BUSCA MOVIMENTOS

select * from Movimento where Ide in (select Movimento__Ide from Financeiro_Caixa where Ide = ‘IDEAQUI’)

select * from Movimento where Ide in (select Movimento__Ide from Financeiro_Caixa where Ide = ‘3c1be00d-fa97-4466-b9f7-ab5038da3afd’)

select * from Movimento where Ide in (select Movimento__Ide from Financeiro_Caixa where Ide = ‘3fd6b446-3628-40e9-851c-2f837fcb3284’)

 

NÃO SALVA CADASTRO DE PRODUTOS E NÃO CLONA

update produto set status= ‘0’, Inativo = ‘1’, Bloqueado = ‘1’, BloqueadoParaVenda = ‘1’ where status = ‘-1’

PROBLEMA RECORRENTE NA 1.30.0 SEMPRE QUANDO UM PRODUTO É EXCLUIDO

 

ERRO USUÁRIO ROOT

Comando para quando bridge não sincroniza por falha no usuário.

update Funcionario set Liberado = 1 where Codigo = 1

 

AUTORIZA NFC-E DUPLICADA

UPDATE Movimento_NFe set Codigo_Status = ‘100’ WHERE Movimento__Ide IN(select ide from Movimento where Sequencia in(‘xxxxxx’ separadas por vírgula e aspas só na primeira seq))

 

ERRO PRODUTO EXCLUÍDO

NOS CASOS EM QUE OCORRER ERRO NO BRIDGE E ESTES FOREM POR CONTA DE PRODUTOS EXCLUIDOS UTILIZAR COMANDO ABAIXO.

update produto set status= ‘0’, Inativo = ‘1’, Bloqueado = ‘1’, BloqueadoParaVenda = ‘1’ where status = ‘-1’

 


MIGRAÇÃO E CONVERSÃO

PROGRAMA CEST PARA SER ATUALIZADO AO EMITIR AS NOTAS

UPDATE PRODUTO SET CEST= ‘00000000-0000-0000-0000-000000000000’, ULTIMA_ALTERACAO=GETDATE()
DELETE FROM CEST WHERE CODIGO=”

 

AJUSTA PREÇO

UPDATE PRODUTOPRECO SET PRECO=PRECO/100 WHERE TABELAPRECO__IDE=(SELECT IDE FROM TABELAPRECO WHERE NOME=’VENDA’)

 

AJUSTA PARA EXPORTAR PARA BALANÇA – Antes da 30

update produto set Fracionado=1,Departamento=1, Exportar_Balanca=1 where Unidade_Venda__Ide in
(select ide from unidades where unidade=’KG’)

 

AJUSTA PARA EXPORTAR PARA BALANÇA – a partir da 33

update produto set Fracionado=1,Departamento=1, Exportar_Balanca=1 where Unidade__Venda__Ide in (select ide from UnidadeMedida where Codigo=’KG’)

 

INCLUI ZERO NO INICIO DO NCM

update produto set ncm = ‘0’+ncm where len(ncm)=7

 

 

 


Ajude-nos a construir esse documento e outros documentos. Toda ajuda é bem vinda, não existe ajuda maior ou menor, menos ou mais importante que a outra. Você é peça importante, venha construir a Info com a gente.
Envie por e-mail para o Adriano Doria ele irá lhe agradecer 🙏 bastante.