SQL 如何使用查询将 MD5 哈希字符串转换为二进制?
在我的项目中,我有一个用户表,其中密码经过 MD5 哈希处理并存储为二进制 (16)。现在我想将这些用户数据作为 INSERT 查询写入 .sql 文件,以便客户可以再次将它们导入回来?
或者有没有办法直接导出这些数据?我尝试使用从Excel到Access文件的DTS,但导入时出现几个错误,我不知道为什么?或者除了MSSQL Server之外还有其他工具可以做到这一点吗?
到目前为止,现在我正在使用分离/附加整个数据库发送给客户,我认为这不是一个好方法?
谢谢,
In my project, I have a user table where password is MD5 hashed and stored as binary(16). Now I want to write those user data as INSERT queries to a .sql file so that customer can import them back again?
Or is there anyway to export those data directly? I tried DTS using from Excel to Access file but when importing, there are several errors occur that I don't know why? Or is there any other tool besides MSSQL Server that can do this?
So far, now I'm using detach/attach the whole database to send to the customer which I think is not really a good way?
Thanks,
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
有人发布了我的问题的答案并立即将其删除?他建议我使用 HASHBYTES 这正是我正在寻找的。谢谢!
Someone posted an answer to my question and deleted it right away? He suggested me to use HASHBYTES which is exactly what I'm looking for. Thanks!