what's wrong in this procedure?

Поиск
Список
Период
Сортировка
От Camaleon
Тема what's wrong in this procedure?
Дата
Msg-id 080608d1-b5ea-4b40-8042-f21867f97cc8@glegroupsg2000goo.googlegroups.com
обсуждение исходный текст
Ответы Re: what's wrong in this procedure?  (Adrian Klaver <adrian.klaver@gmail.com>)
Re: what's wrong in this procedure?  (Rob Sargent <robjsargent@gmail.com>)
Re: what's wrong in this procedure?  (Vibhor Kumar <vibhor.kumar@enterprisedb.com>)
Список pgsql-sql
This error is returned Erro de SQL:

ERROR:  column "Aguardando Pagto" does not exist at character 352  >>>


create or replace function get_historico()   RETURNS SETOF twiste.type_cur__historico AS '
  SELECT o.data_fim, sum(t.num_itens * t.valor) AS total, count(t.*) AS transacoes  FROM ofertas o  JOIN transacao t ON
o.ofertas_id= t.ofertas_id  JOIN municipio m ON o.municipio_id = m.municipio_id WHERE  o.data_fim <= now() AND t.status
IN("AguardandoPagto", "Em análise", "Aprovado", "Completo") GROUP BY o.data_fim; 
'
language 'sql';



>> the column is t.status and not "Aguardando Pagto";
>> what's wrong ?  thanks


В списке pgsql-sql по дате отправления:

Предыдущее
От: "Jacques Lebrun"
Дата:
Сообщение: Problem with serial counters
Следующее
От: Adrian Klaver
Дата:
Сообщение: Re: what's wrong in this procedure?