Skip to content

Instantly share code, notes, and snippets.

@jtperreault
Last active December 14, 2015 04:59
Show Gist options
  • Save jtperreault/5032517 to your computer and use it in GitHub Desktop.
Save jtperreault/5032517 to your computer and use it in GitHub Desktop.
CREATE UNIQUE NONCLUSTERED INDEX index_users_reset_password_token
ON dbo.users (reset_password_token)
WHERE reset_password_token IS NOT NULL
ALTER INDEX index_users_on_reset_password_token
ON dbo.users (reset_password_token)
WHERE reset_password_token IS NOT NULL
REBUILD
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment