Problem with function, type cast?

Поиск
Список
Период
Сортировка
От A B
Тема Problem with function, type cast?
Дата
Msg-id dbbf25900805150747w15e47542ra6fb5924b30bd0eb@mail.gmail.com
обсуждение исходный текст
Ответы Re: Problem with function, type cast?
Список pgsql-novice
I have written this little silly function

CREATE OR REPLACE FUNCTION recordMail(customerId_ integer, message_
VARCHAR(240)) RETURNS void AS $$
BEGIN
       INSERT INTO MailRecord (custid,message) VALUES (customerId_, message_);
END;
$$ LANGUAGE plpgsql;

And it is created, and then I do:

select recordMail(10,'asd');

and I get


ERROR:  function recordmail(integer, "unknown") does not exist
LINE 1: select recordMail(10,'asd');
              ^
HINT:  No function matches the given name and argument types. You may
need to add explicit type casts.



Isn't postgresql supposed to be able to convert it to a suitable
datatype and find the matching function?

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

Предыдущее
От: "A B"
Дата:
Сообщение: type cast of function arguments
Следующее
От: Tom Lane
Дата:
Сообщение: Re: type cast of function arguments