Facebook
From Corrupt Hamster, 3 Years ago, written in Plain Text.
Embed
Download Paste or View Raw
Hits: 100
  1. select SUM(QtdFaturamento) * 2 from MetaFaturamento2
  2. where UnidadeNegocioOrigemId = '25B21F27-5CA1-4F7E-71BD-08D747A81758'
  3. and UnidadeNegocioDestinoId = '062E874D-B5A1-4BBA-992B-08D745D673A1'
  4. and ProdutoId = '4D45A192-6BEF-4973-52B7-08D748261BFD'
  5. and CAST(DataFaturamento as date) = '2020-10-05'
  6.  
  7.  
  8. select [dbo].[Calcular_FaturadoD0] (
  9.         '25B21F27-5CA1-4F7E-71BD-08D747A81758',
  10.         '062E874D-B5A1-4BBA-992B-08D745D673A1',
  11.         '4D45A192-6BEF-4973-52B7-08D748261BFD',
  12.         null,
  13.         '2020-10-05'
  14. )
  15.  
  16.  
  17. select *  from [vwMetaTransferencia]
  18. where UnidadeNegocioOrigemId = '25B21F27-5CA1-4F7E-71BD-08D747A81758'
  19. and UnidadeNegocioDestinoId = '062E874D-B5A1-4BBA-992B-08D745D673A1'
  20. and ProdutoId = '4D45A192-6BEF-4973-52B7-08D748261BFD'
  21. and CAST(DataReferencia as date) = '2020-10-05'