Tabela SOG

Retorno integração TOTVS MES
25camposNome físicoSOG010(empresa 01)

Campos da tabela SOG

25 campos no dicionário de dados do TOTVS Protheus.

25
CampoDescrição
OG_FILIAL
Caractere (C)(2)
Filial
Contexto:
Real
OG_TRANSAC
Caractere (C)(10)
Transacao
Contexto:
Real
OG_OP
Caractere (C)(13)
Ordem produc
Contexto:
Real
OG_PRODUTO
Caractere (C)(15)
Produto
Máscara:
@!
Contexto:
Real
OG_STATUS
Caractere (C)(1)
Status
Máscara:
@!
Contexto:
Real
OG_RECURSO
Caractere (C)(6)
Recurso
Contexto:
Real
OG_DATA
Data (D)(8)
Data recebim
Contexto:
Real
OG_HORA
Caractere (C)(8)
Hora receb.
Contexto:
Real
OG_DTAPONT
Data (D)(8)
Dt Ini Apont
Contexto:
Real
OG_HRAPONT
Caractere (C)(8)
Hr Ini Apont
Contexto:
Real
OG_DTFIMAP
Data (D)(8)
Dt Fim Apont
Contexto:
Real
OG_HRFIMAP
Caractere (C)(8)
Hr Fim Apont
Contexto:
Real
OG_QUANTID
Numérico (N)(11,2)
Qtd Apont
Máscara:
@E 99,999,999.99
Contexto:
Real
OG_ESTORNO
Caractere (C)(1)
Estorno
Contexto:
Real
OG_OPERAC
Caractere (C)(2)
Operacao
Máscara:
@!
Contexto:
Real
OG_SEQ
Numérico (N)(10)
Sequencial
Máscara:
@E 9,999,999,999
Contexto:
Real
OG_XML
Memo (M)(999)
Conteudo
Contexto:
Real
OG_MSGRET
Memo (M)(999)
Msg Retorno
Contexto:
Real
OG_MOTIVO
Caractere (C)(10)
Motivo
Contexto:
Real
OG_TPMV
Caractere (C)(1)
Tipo movto
Contexto:
Real
OG_PRODST
Caractere (C)(15)
Prod Destino
Máscara:
@!
Contexto:
Real
OG_PROORG
Caractere (C)(15)
Prod Origem
Máscara:
@!
Contexto:
Real
OG_LOCORG
Caractere (C)(2)
Local origem
Contexto:
Real
OG_LOCDST
Caractere (C)(2)
Local destin
Contexto:
Real
OG_IDMES
Caractere (C)(250)
ID TOTVSMES
Contexto:
Real

SELECT de exemplo da tabela SOG

No Protheus a tabela física leva o código da empresa (01 → 010) e registros excluídos ficam com D_E_L_E_T_ = '*'.

SQL · SQL Server
SELECT TOP 100
  SOG.OG_FILIAL,
  SOG.OG_TRANSAC,
  SOG.OG_OP,
  SOG.OG_PRODUTO,
  SOG.OG_STATUS,
  SOG.OG_RECURSO,
  SOG.OG_DATA,
  SOG.OG_HORA
FROM SOG010 SOG
WHERE SOG.D_E_L_E_T_ = ' '

Tabelas próximas no índice do Protheus

O ERPSeeker é um projeto independente, sem vínculo com a TOTVS. A estrutura pode variar conforme a versão e as customizações do seu ambiente.