Reputation: 402
I've got a column user_password
where passwords are stored with bytea
datatype.
I want to select all columns in this table, and password to be converted in the results into MD5.
Currently examplary password is like this 4\323\227\120\0817Z\303\101
I'm using postgresql.
Upvotes: 0
Views: 440
Reputation: 402
Jeeez. It was so easy I didn't even realized. just select md5(login_password) worked.
Upvotes: 0
Reputation: 1529
Using update query
update table_name set user_password = MD5(user_password)
Upvotes: 1