By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
464,779 Members | 1,185 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 464,779 IT Pros & Developers. It's quick & easy.

Unable to identify a function that satisfies the given argument types

P: n/a
Why do I keep getting this error in the function to insert data below,
any help would be apprecaited:

CREATE OR REPLACE FUNCTION public.add_apppointment (date, time,
integer,time, boolean, text, integer, integer, varchar, integer,
boolean, varchar, varchar[], integer[]) RETURNS text AS'
declare
v_appt_date date ;
v_end_time time;
v_appt_duration int2;
v_start_time time;
v_canceled_flag boolean;
v_memo text;
v_start_slot_id int2;
v_end_slot_id int2;
v_room_id varchar;
v_patient_id int4;
v_out_of_town boolean;
v_procedure_cd varchar;
v_ancillary_proc varchar[];
v_practitioner_id int4[];

v_patient_name text;
v_pat_phone text;

v_status text;

BEGIN
v_appt_date = $1 ;
v_end_time = $2;
v_appt_duration $3;
v_start_time = $4;
v_canceled_flag = $5;
v_memo = $6;
v_start_slot_id = $7;
v_end_slot_id = $8;
v_room_id = $9;
v_patient_id = $10;
v_out_of_town = $11;
v_procedure_cd = $12;
v_ancillary_proc = $13;
v_practitioner_id = $14;

v_pat_phone := cast (get_phone(v_patient_id) as varchar);
v_patient_name := get_name(v_patient_id);
insert into appointment values(default,
$1 ,
$2,
$3,
$4,
$5 ,
$6,
$7,
$8,
v_patient_name,
v_patient_phone,
$9,
$10,
$11,
$12,
$13,
$14) ;

return v_status;
END;
'LANGUAGE 'plpgsql' VOLATILE CALLED ON NULL INPUT SECURITY INVOKER;

ERROR: Function add_appointment(date, time without time zone,
smallint, time without time zone, boolean, text, smallint, smallint,
character varying, integer, boolean, character varying, character
varying[], integer[]) does not exist
Unable to identify a function that satisfies the given
argument types
You may need to add explicit typecasts
dev06=#

Thnaks

Ayokunle Giwa
Jul 19 '05 #1
Share this Question
Share on Google+
1 Reply

P: n/a
On 4 Mar 2004 15:57:31 -0800, Ayokunle Giwa <ag***@cox.net> wrote:
CREATE OR REPLACE FUNCTION public.add_apppointment (date, time, ERROR: Function add_appointment(date, time without time zone,


See the subtle difference? apppointment/appointment

-JFL
Jul 19 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.