CREATE TABLE IF NOT EXISTS dbo.Serv(
	CODIGO varchar(10) NULL,
	PREVISTA datetime NULL,
	RAZAO varchar(50) NULL,
	MODELO nvarchar(40) NULL,
	SERIE varchar(50) NULL,
	MECANICO numeric(18, 0) NULL,
	MECANICO2 numeric(18, 0) NULL,
	NUMGARANT varchar(50) NULL,
	SOLICITADO varchar(50) NULL,
	CLIENTE numeric(18, 0) NULL,
	TIPOPRECO int NULL,
	MARCA varchar(50) NULL,
	TIPO int NULL,
	PAGAMENTO numeric(18, 0) NULL,
	LOCAL int NULL,
	SAIDALOJA1 varchar(50) NULL,
	SAIDALOJA2 varchar(50) NULL,
	ENTRACLI1 varchar(50) NULL,
	ENTRACLI2 varchar(50) NULL,
	SAIDACLI1 varchar(50) NULL,
	SAIDACLI2 varchar(50) NULL,
	RETORLOJA1 varchar(50) NULL,
	RETORLOJA2 varchar(50) NULL,
	PRONTA datetime NULL,
	ABERTURA datetime NULL,
	ENTREGUE datetime NULL,
	FECHAMENTO datetime NULL,
	RETORNO datetime NULL,
	POS varchar(50) NULL,
	CANCELA datetime NULL,
	NF varchar(50) NULL,
	DATANF datetime NULL,
	GARANTIA datetime NULL,
	REVENDEDOR varchar(50) NULL,
	DEFEITO varchar(50) NULL,
	CSDEFEITO varchar(50) NULL,
	APLICADA varchar(50) NULL,
	OUTROSSER numeric(18, 0) NULL,
	TIPOMAQ numeric(18, 0) NULL,
	TOTAL float NULL,
	TOTALPROD float NULL,
	VLSERVICO numeric(18, 0) NULL,
	DESCPECA numeric(18, 0) NULL,
	DESCSERV numeric(18, 0) NULL,
	CODSERV numeric(18, 0) NULL,
	SERVICO varchar(50) NULL,
	OBSSERV1 varchar(200) NULL,
	OBSSERV2 varchar(200) NULL,
	TOTALCOMIS double NULL,
	PAGODINH double NULL,
	PAGOCHEQUE double NULL,
	PAGOBOLETO double NULL,
	PAGODUPLIC double NULL,
	PAGOCONTA double NULL,
	PAGOTROCA double NULL,
	DEFRECLAM1 varchar(200) NULL,
	DEFRECLAM2 varchar(200) NULL,
	CARACTENT1 varchar(200) NULL,
	CARACTENT2 varchar(200) NULL,
	DEFEITENT1 varchar(200) NULL,
	DEFEITENT2 varchar(200) NULL,
	DEFEITENC1 varchar(200) NULL,
	DEFEITENC2 varchar(200) NULL,
	DEFEITENC3 varchar(200) NULL,
	DEFEITENC4 varchar(200) NULL,
	ANO varchar(50) NULL,
	SEQUENCIA varchar(50) NULL,
	OBSRETORNO varchar(150) NULL,
	VENDEDOR varchar(60) NULL,
	IMPRESSO int NULL,
	ECF varchar(50) NULL,
	NFSAIDA varchar(50) NULL,
	DNF datetime NULL,
	EC numeric(18, 0) NULL,
	AC varchar(50) NULL,
	FORNEC numeric(18, 0) NULL,
	NOMEFORNEC varchar(50) NULL,
	RETTERC datetime NULL,
	NOMERET varchar(50) NULL,
	ENTRTERC datetime NULL,
	NOMEENT varchar(50) NULL,
	OBSTERC1 varchar(200) NULL,
	OBSTERC2 varchar(200) NULL,
	OBSTERC3 varchar(200) NULL,
	OBSTERC4 varchar(200) NULL,
	OBSTERC5 varchar(200) NULL,
	PAGODEP double NULL,
	VALORPECA double NULL,
	VALORPROM double NULL,
	TINF varchar(50) NULL,
	VENDED numeric(18, 0) NULL,
	STATUS varchar(50) NULL,
	INDCODIGO numeric(18, 0) NULL,
	CODAUTORI varchar(20) NULL,
	ValorMO float NULL,
	Fone1 varchar(16) NULL,
	Obs1 varchar(50) NULL,
	obs2 varchar(50) NULL,
	recebido varchar(50) NULL,
	aprovacao numeric(18, 0) NULL,
	garantia1 datetime NULL,
	dtemissao datetime NULL,
	dtorcam datetime NULL,
	nnf numeric(18, 0) NULL,
	EQUIPaMENTo nvarchar(50) NULL,
	COMISSAO float NULL,
	Garan varchar(50) NULL,
	PrazoEnt varchar(50) NULL,
	Condi varchar(50) NULL,
	Posicao varchar(50) NULL,
	Temp1 varchar(50) NULL,
	Temp2 varchar(50) NULL,
	Dataaprova datetime NULL,
	CamTr smallint NULL,
	CamFr smallint NULL,
	Toque smallint NULL,
	Vol smallint NULL,
	Home smallint NULL,
	Fone smallint NULL,
	Microf smallint NULL,
	Flash smallint NULL,
	SenPro smallint NULL,
	Ausc smallint NULL,
	Power smallint NULL,
	AltoF smallint NULL,
	ConDock smallint NULL,
	Tela smallint NULL,
	Carc smallint NULL,
	ObsChk text NULL,
	CelNLiga char(1) NULL,
	Senha varchar(30) NULL,
	CamTrS smallint NULL,
	CamFrS smallint NULL,
	ToqueS smallint NULL,
	VolS smallint NULL,
	HomeS smallint NULL,
	FoneS smallint NULL,
	MicrofS smallint NULL,
	FlashS smallint NULL,
	SenProS smallint NULL,
	AuscS smallint NULL,
	PowerS smallint NULL,
	AltoFS smallint NULL,
	ConDockS smallint NULL,
	TelaS smallint NULL,
	CarcS smallint NULL,
	ObsChkS text NULL,
	CelNLigaS char(1) NULL,
	ChaveCF varchar(44) NULL,
	CaminhoXMLC varchar(200) NULL,
	CPF char(20) NULL,
	ChaveCanc varchar(50) NULL,
	Reg_Filial int NULL,
	PagoCartCr double(10, 2) NULL,
	PagoCartDe double(10, 2) NULL,
	MotivoCancela varchar(150) NULL,
	PathRPS varchar(50) NULL,
	RPS int NULL,
	Marca2 varchar(1) NULL,
	NFSSAIDA int NULL,
	Dia1 int NULL,
	Dia2 int NULL,
	Dia3 int NULL,
	Dia4 int NULL,
	Dia5 int NULL,
	Dia6 int NULL,
	Dia7 int NULL,
	Dia8 int NULL,
	Dia9 int NULL,
	Dia10 int NULL,
	Dia11 int NULL,
	Dia12 int NULL,
	Dia13 int NULL,
	Dia14 int NULL,
	Dia15 int NULL,
	Dia16 int NULL,
	Dia17 int NULL,
	Dia18 int NULL,
	Dia19 int NULL,
	Dia20 int NULL,
	Dia21 int NULL,
	Dia22 int NULL,
	Dia23 int NULL,
	Dia24 int NULL,
	Vencto1 datetime NULL,
	Vencto2 datetime NULL,
	Vencto3 datetime NULL,
	Vencto4 datetime NULL,
	Vencto5 datetime NULL,
	Vencto6 datetime NULL,
	Vencto7 datetime NULL,
	Vencto8 datetime NULL,
	Vencto9 datetime NULL,
	Vencto10 datetime NULL,
	Vencto11 datetime NULL,
	Vencto12 datetime NULL,
	Vencto13 datetime NULL,
	Vencto14 datetime NULL,
	Vencto15 datetime NULL,
	Vencto16 datetime NULL,
	Vencto17 datetime NULL,
	Vencto18 datetime NULL,
	Vencto19 datetime NULL,
	Vencto20 datetime NULL,
	Vencto21 datetime NULL,
	Vencto22 datetime NULL,
	Vencto23 datetime NULL,
	Vencto24 datetime NULL,
	Val1 double(10, 2) NULL,
	Val2 double(10, 2) NULL,
	Val3 double(10, 2) NULL,
	Val4 double(10, 2) NULL,
	Val5 double(10, 2) NULL,
	Val6 double(10, 2) NULL,
	Val7 double(10, 2) NULL,
	Val8 double(10, 2) NULL,
	Val9 double(10, 2) NULL,
	Val10 double(10, 2) NULL,
	Val11 double(10, 2) NULL,
	Val12 double(10, 2) NULL,
	Val13 double(10, 2) NULL,
	Val14 double(10, 2) NULL,
	Val15 double(10, 2) NULL,
	Val16 double(10, 2) NULL,
	Val17 double(10, 2) NULL,
	Val18 double(10, 2) NULL,
	Val19 double(10, 2) NULL,
	Val20 double(10, 2) NULL,
	Val21 double(10, 2) NULL,
	Val22 double(10, 2) NULL,
	Val23 double(10, 2) NULL,
	Val24 double(10, 2) NULL,
	Deducao double(10, 2) NULL,
	DataFat datetime NULL,
	DataCF datetime NULL,
	CF varchar(10) NULL,
	Testou varchar(3) NULL,
	Caixa int NULL,
	FuncCancela int NULL,
	NomeCancela varchar(100) NULL,
	FuncAbertura int NULL,
	NomAbertura varchar(100) NULL,
	MovEstoquePecas int NULL,
	TxUnicaDeb double(10, 2) NULL,
	TxMensalDeb double(10, 2) NULL,
	TxUnicaCred double(10, 2) NULL,
	TxMensalCred double(10, 2) NULL,
	OBSNF text NULL,
	CodTribServ int NULL,
	Orcamento varchar(10) NULL,
	PathNFSe varchar(250) NULL,
	ProtNFs varchar(30) NULL,
	DNFs datetime NULL,
	Comis double(10, 2) NULL,
	TotComis double(10, 2) NULL,
	Boleto varchar(1) NULL,
	Setor varchar(50) NULL,
	Numerador varchar(10) NULL,
	NFE varchar(10) NULL,
	Placa varchar(10) NULL,
	DataNFe datetime NULL,
	Protocolo varchar(20) NULL,
	Recibo varchar(20) NULL,
	PathNFE varchar(100) NULL,
	CodMaquina char(10) NULL,
	DiaNFe1 int NULL,
	DiaNFe2 int NULL,
	DiaNFe3 int NULL,
	DiaNFe4 int NULL,
	DiaNFe5 int NULL,
	DiaNFe6 int NULL,
	DiaNFe7 int NULL,
	DiaNFe8 int NULL,
	DiaNFe9 int NULL,
	DiaNFe10 int NULL,
	DiaNFe11 int NULL,
	DiaNFe12 int NULL,
	VenctoNFe1 datetime NULL,
	VenctoNFe2 datetime NULL,
	VenctoNFe3 datetime NULL,
	VenctoNFe4 datetime NULL,
	VenctoNFe5 datetime NULL,
	VenctoNFe6 datetime NULL,
	VenctoNFe7 datetime NULL,
	VenctoNFe8 datetime NULL,
	VenctoNFe9 datetime NULL,
	VenctoNFe10 datetime NULL,
	VenctoNFe11 datetime NULL,
	VenctoNFe12 datetime NULL,
	ValNFe1 double(10, 2) NULL,
	ValNFe2 double(10, 2) NULL,
	ValNFe3 double(10, 2) NULL,
	ValNFe4 double(10, 2) NULL,
	ValNFe5 double(10, 2) NULL,
	ValNFe6 double(10, 2) NULL,
	ValNFe7 double(10, 2) NULL,
	ValNFe8 double(10, 2) NULL,
	ValNFe9 double(10, 2) NULL,
	ValNFe10 double(10, 2) NULL,
	ValNFe11 double(10, 2) NULL,
	ValNFe12 double(10, 2) NULL,
	OS_DT_ENV datetime NULL,
	OS_HR_ENV char(10) NULL,
	ODB_DT_ENV datetime NULL,
	ODB_HR_ENV char(10) NULL,
	Reaberto datetime NULL,
	PRIMARY KEY (CODIGO)
)ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8;

