| From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
|---|---|
| To: | Todd Kover <kovert(at)omniscient(dot)com> |
| Cc: | pgsql-novice(at)postgresql(dot)org |
| Subject: | Re: arrays and functions in plpgsql |
| Date: | 2004-09-18 01:41:13 |
| Message-ID: | 27899.1095471673@sss.pgh.pa.us |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-novice |
Todd Kover <kovert(at)omniscient(dot)com> writes:
> indeed I did. Still have the same problem, though:
> create or replace function float8_jitter_add(float8[], interval)
> ...
> testdb=# select float8_jitter_add('{.1,.2,.3,1}', 5);
> ERROR: "$1" is declared CONSTANT
> CONTEXT: compile of PL/pgSQL function "float8_jitter_add" near line 12
Hmm, that's weird ... [ cut ... paste ... ]
...
CREATE FUNCTION
regression=# select float8_jitter_add('{.1,.2,.3,1}', 5);
ERROR: function float8_jitter_add("unknown", integer) does not exist
HINT: No function matches the given name and argument types. You may need to add explicit type casts.
[ think ... ] Oh. You are creating float8_jitter_add(float8[], interval)
whereas this call is going to invoke float8_jitter_add(float8[], integer)
or something compatible with that. You're seeing a syntax error in a
different, pre-existing function with a similar name.
FWIW, 8.0 has a number of improvements in error reporting that will
hopefully make this sort of problem more transparent.
regards, tom lane
| From | Date | Subject | |
|---|---|---|---|
| Next Message | M. Bastin | 2004-09-18 12:44:20 | Re: ERROR: COPY <Table Name> FROM <file> |
| Previous Message | Todd Kover | 2004-09-18 00:31:13 | Re: arrays and functions in plpgsql |