Jump to content
Seja Membro VIP - Remova Banners de Propagandas, Tenha Liberado Qualquer Download, Além de Acessos em Áreas Exclusivas!! ×

Recommended Posts


  • Topic Count:  20
  • Topics Per Day:  0.00
  • Content Count:  61
  • Content Per Day:  0.01
  • Reputation:   0
  • Achievement Points:  500
  • Solved Content:  0
  • Days Won:  0
  • Status:  Offline
  • Age:  33

Posted

Boa tarde pessoal,

Estou convertendo um relatório do Delphi p/ .NET do extrato, porém estou com um problema no retorno de uma consulta:

SELECT SUM(VALOR) FROM FXCX
WHERE DATACOMPENSACAO=:FILTRO#1 
AND DATA<:FILTRO#1
AND CODCXA=:CODCXA

Informo os parâmetros 01/10/2014 e 0005 que são data inicial da geração e o código da conta caixa, se pego essa consulta e rodo no Management Studio ele me retorna o valor -3781.4100 mas quando executo pelo RM ele não me retorna uma coluna em branco. Sabem alguma forma de resolver isso? Já tentei com converter pra string, double e nada funcionou.

  • Replies 2
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic


  • Topic Count:  14
  • Topics Per Day:  0.00
  • Content Count:  165
  • Content Per Day:  0.04
  • Reputation:   6
  • Achievement Points:  983
  • Solved Content:  0
  • Days Won:  2
  • Status:  Offline

Posted

Tenta colocar assim:

SELECT SUM(VALOR) FROM FXCX
WHERE CAST(DATACOMPENSACAO AS DATE)=:FILTRO#1
AND CAST(DATA AS DATE)<:FILTRO#1
AND CODCXA=:CODCXA

Pode ser isso também...


  • Topic Count:  920
  • Topics Per Day:  0.13
  • Content Count:  9,060
  • Content Per Day:  1.32
  • Reputation:   351
  • Achievement Points:  108,849
  • Solved Content:  0
  • Days Won:  220
  • Status:  Offline
  • Age:  52
  • Device:  Windows

Posted

Tenta digitar a data em outro formato para verificar se está em formato americano por exemplo...

Tenta '10/01/2014' (mm/dd/aaaa) ou até '2014-10-01' (aaaa/mm/dd)

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.