0

hi to all,

I want to ask about GUID. what is the main use of GUID in our database.
I have seen that many developers uses GUID in user table(contains username and password)
and they update GUID of that user each time when user login.
In asp.net I have created GUID using System.GUID.newGUID().

3
Contributors
4
Replies
5
Views
7 Years
Discussion Span
Last Post by sknake
0

well it depends on your database..
on creating user i add a column GUID and assign default value to column using
newid() function in sqlserver 2005/08..

start with scenario..
say i forgot my password..
i will ask user to give me the username
depend on that i will grab email address and guid..

now i will setup a link to my site which holds
the user's email address and Guid..
and send email to user..

when user cliks the link, it gets redirected to my site
so on page load i check if Guid and email matches correctly then
allow now user to change the password...

hope that helps !

This question has already been answered. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.