Tabela DTN

Complemento de Regiões
9camposNome físicoDTN010(empresa 01)

Campos da tabela DTN

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

9
CampoDescrição
DTN_FILIAL
Caractere (C)(2)
Filial
DTN_GRPVEN
Caractere (C)(6)
Grupo
Máscara:
@!
Consulta F3:
DUY
Validação:
ExistCpo("DUY",M->DTN_GRPVEN,1) .And. ExistChav("DTN", M->DTN_GRPVEN)
DTN_DESGRP
Caractere (C)(30)
Descricao
Máscara:
@!
Contexto:
Virtual (não existe no banco)
DTN_ITEM
Caractere (C)(2)
Item
Máscara:
@!
DTN_SERTMS
Caractere (C)(1)
Serv.Transp.
Máscara:
@!
Consulta F3:
DLC
Validação:
Pertence("23")
DTN_DESSVT
Caractere (C)(30)
Desc.Sv.Tran
Máscara:
@!
Contexto:
Virtual (não existe no banco)
DTN_TIPTRA
Caractere (C)(1)
Tipo Transp.
Máscara:
@!
Consulta F3:
DLC
Validação:
TMSValField("M->DTN_TIPTRA",.T.,"DTN_DESTPT")
DTN_DESTPT
Caractere (C)(30)
Desc.Tp.Tran
Máscara:
@!
Contexto:
Virtual (não existe no banco)
DTN_TIPREG
Caractere (C)(1)
Tipo Regiao
Máscara:
@!
Validação:
Pertence("123")
3 valores possíveis
  • 1Origem
  • 2Destino
  • 3Ambos

SELECT de exemplo da tabela DTN

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
  DTN.DTN_FILIAL,
  DTN.DTN_GRPVEN,
  DTN.DTN_ITEM,
  DTN.DTN_SERTMS,
  DTN.DTN_TIPTRA,
  DTN.DTN_TIPREG
FROM DTN010 DTN
WHERE DTN.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.