Is there a way to obtain a unique database identifier (such as a GUID) from a SQL 2005 database?
I found this article: http://msdn.microsoft.com/en-us/library/micr
I don't know which GUID SMO returns, but you could use
select service_broker_guid from sys.databases
which is != Guid.Empty for all databases except master and model.
I found that not all databases have a NOT NULL sys.database_recovery_status.database_guid, as was suggested by Remus.
Tests done on SQL2008