Re: La fonction crypt de Postgresql
Le 12293ième jour après Epoch,
Georges Roux écrivait:
> Salut à tous,
>
> J'ai un probleme avec la fonction crypt de postgresql.
>
> je doit inserer une donnée dans un champ de ma base, et je veux la
> chiffrer avec MD5
> il y a une foonction postgresql pour ca, elle depend du paquet
> postgresql-contrib
>
> je l'utilise donc avec un
> update utilsateurs set crypt=crypt('inode',gen_salt('md5')) where
> id='lambda';
>
> voici l'erreur:
> ERROR: Function gen_salt("unknown") does not exist
> Unable to identify a function that satisfies the given
> argument types
> You may need to add explicit typecasts
>
> pourtant la doc fournie avec postgresql-contrib decrit bien la
> fonction qui devrait être reconnue.
> /usr/share/doc/postgresql-contrib/README.pgcrypto.gz
Je vais peut-être dire une bêtise, mais tu as installé le module dans la
base ? Il doit y avoir un make install à faire.
Regarde si par hasard il n'y aurait pas un fichier crypto.sql qui permet
de déclarer les fonctions.
--
"The trouble with doing something right the first time is that nobody
appreciates how difficult it was."
-- Walt West
Reply to: