Sql 如何将密码转换为MD5
我有一个列user\u password,其中密码存储为bytea数据类型 我想选择此表中的所有列,以及要在结果中转换为MD5的密码 当前示例密码如下4\323\227\120\0817Z\303\101 我正在使用postgresql。使用更新查询Sql 如何将密码转换为MD5,sql,postgresql,passwords,Sql,Postgresql,Passwords,我有一个列user\u password,其中密码存储为bytea数据类型 我想选择此表中的所有列,以及要在结果中转换为MD5的密码 当前示例密码如下4\323\227\120\0817Z\303\101 我正在使用postgresql。使用更新查询 update table_name set user_password = MD5(user_password) 哎呀。这太容易了,我都没意识到。只需选择md5login\u password worked.但我不想修改表本身,只想显示转换后的
update table_name set user_password = MD5(user_password)
哎呀。这太容易了,我都没意识到。只需选择md5login\u password worked.但我不想修改表本身,只想显示转换后的结果