Search Postgresql Archives

Re: invalid regular expression: invalid backreference number

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Jeff Ross <jross@xxxxxxxxxx> writes:
> To debug this I've extracted the code into its own function:

> CREATE FUNCTION gen_password() RETURNS text AS $$
> DECLARE
>   password text;
>   chars := 'abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789';
> BEGIN

You forgot to give a type for the "chars" variable.

> psql:create_password.sql:12: ERROR:  invalid type name ""
> CONTEXT:  compile of PL/pgSQL function "gen_password" near line 3

I agree that this is a pretty awful error message :-( ... will take a
look at whether it can be improved.

			regards, tom lane


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux