A co-worker recently ran into a situation where a query to look up security permissions was taking ~15 seconds to run using an = comparison on UserID (which is a UNIQUEIDENTIFIER). Needless to say, the users were less than impressed.
Out of frustration, my co-worker changed the = comparison to use a LIKE and the query sped up to under 1 second.
Without knowing anything about the data schema (I don't have access to the database or execution plans), what could potentially cause this change in performance?
(Broad and vague question, I know)