From: | Sebastián Villalba <sebastian(at)fcm(dot)unc(dot)edu(dot)ar> |
---|---|
To: | =?ISO-8859-1?Q?Javier_Berm=FAdez_Ti?=to <javier_bt(at)hotmail(dot)com>, pgsql-es-ayuda(at)postgresql(dot)org |
Subject: | Re: Error Modificacion de clave de usuario |
Date: | 2006-07-06 00:17:05 |
Message-ID: | 20060706001420.M57237@fcm.unc.edu.ar |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-es-ayuda |
Hola Javier.
On Wed, 05 Jul 2006 22:17:23 +0000, Javier Bermúdez Tito wrote
>
> create or replace function fu_cambia_clave(pc_user varchar(5),
> pc_clave varchar(10)) returns varchar as $body$ begin ALTER
> USER pc_user ENCRYPTED PASSWORD pc_clave NOCREATEDB NOCREATEUSER;
> return 'ok'; end; $body$ language 'plpgsql';
>
> select fu_cambia_clave('00122', 'nuevaclave')
>
> Resultado :
>
> ERROR: syntax error at or near "$1" at character 13
> QUERY: ALTER USER $1 ENCRYPTED PASSWORD $2 NOCREATEDB NOCREATEUSER
> CONTEXT: PL/pgSQL function "fu_cambia_clave" line 2 at SQL statement
Probá con:
create or replace function fu_cambia_clave(pc_user varchar(5),
pc_clave varchar(10)) returns varchar as $body$ begin ALTER
USER pc_user WITH ENCRYPTED PASSWORD pc_clave NOCREATEDB NOCREATEUSER;
return 'ok'; end; $body$ language 'plpgsql';
Saludos...
-
-------------------------------------------
Sebastián Villalba
sebastian(at)fcm(dot)unc(dot)edu(dot)ar
-------------------------------------------
From | Date | Subject | |
---|---|---|---|
Next Message | Javier Bermúdez Tito | 2006-07-06 01:30:46 | ya lo hice Error Modificacion de clave de usuario |
Previous Message | Linder Poclaba | 2006-07-05 23:13:42 | Re: Error Modificacion de clave de usuario |