Re: A SQL problem
Albert Young wrote:
> I have a table storing user information.
> Previously the passwords are stored as plain text. Now our customer asks
> the passowrds to be MD5.
> Is there any simple way of looping on all the rows and update all the passwords?
1) Make sure your password column is (at least) char(32);
2) Issue the following command:
UPDATE users SET password = md5(password);
But beware: there is no way to recover the plain-text passwords after this (which in fact is a good thing).
--
felix
Subject
Written By
Posted
Re: A SQL problem
May 02, 2005 12:40AM
Sorry, you can't reply to this topic. It has been closed.
Content reproduced on this site is the property of the respective copyright holders.
It is not reviewed in advance by Oracle and does not necessarily represent the opinion
of Oracle or any other party.