Regexp to validate MS SQL uniqueidentifier

I’m working on PHP project that interacts with HRNET and at some point I need to validate if given string is valid mssql guid. For this I use php regular expression:
^[0-9a-zA-Z]{8}-[0-9a-zA-Z]{4}-[0-9a-zA-Z]{4}-[0-9a-zA-Z]{4}-[0-9a-zA-Z]{12}$

This entry was posted in Uncategorized and tagged , , . Bookmark the permalink.

2 Responses to Regexp to validate MS SQL uniqueidentifier

Leave a Reply

Your email address will not be published. Required fields are marked *