hi helen... the comma is the less problem...
A correct sql:
select N.DTEMISSAONOTA as DATA,
'DINHEIRO' as MEIO_PAGAMENTO1,
cast('DINHEIRO' as char(10)) as MEIO_PAGAMENTO2,
'00' as MEIO_PAGAMENTO,
N.VLRTOTALNOTA as VALOR,
0 as AUTENT_01,
0
acgomes2...@yahoo.com.br wrote:
> select
> A.Codigo
> 'DINHEIRO' FORMA_PAGTO
> FROM NF A
> where A.dataEmissao between '01.01.2018' and '31.01.2018'
> and A.Modelo = '55'
This should work fine if you place a comma after A.Codigo. It does
not make any sense to ORDER BY 2 (nor ORDER BY 1,2)
hi:
select
A.Codigo
'DINHEIRO' FORMA_PAGTO
FROM NF A
where A.dataEmissao between '01.01.2018' and '31.01.2018'
and A.Modelo = '55'
order by 1, 2
using, "order by 2", return a error but, if i use: cast('DINHEIRO' as
varchar(10)) FORMA_PAGTO does not ocorrur.