Username to SID Assosiation

To find the sid of a user using the username and vice versa use the following command:

wmic useraccount get name,sid