I use this query to create server login. I want to pass password like hash:
PASSWORD = hashed_password HASHED
How can I get the hash?
I use freetds to connect to server.
If you are speaking about existing logins, you can use the Microsoft's sp SP_HELP_REVLOGIN. Here you can find the script to create this sp: http://support.microsoft.com/kb/918992