declare @CabDoc Table ( Codigo int, Data datetime, Entid...


Please login or register to vote for this query.

(click on this box to dismiss)

History of Science and Math

Q&A for people interested in the history and origins of science and mathematics

declare @CabDoc Table

Codigo int,
Data datetime,
Entidade int,
Valor int

declare @LinDoc Table

CodigoCabDoc int,
NumLinha int,
CodArtigo nvarchar(max),
Descricao nvarchar(max),
Quantidade int,
PrecoUnitario int


select 1 where getdate() between cast('2013-06-20' as datetime) and cast('2013-06-22' as datetime) 
Select * 
  From @CabDoc CabDoc
 Inner Join @LinDoc LinDoc
         On LinDoc.CodigoCabDoc = Codigo
        And LinDoc.CodArtigo = 'XPTO'
 --Where CabDoc.Data between

Enter Parameters

Switch to meta site
loading Hold tight while we fetch your results