Hi everyone,
  I really think I need explanations on what is going on behind the scene when attaching a ".mdf" database to either SQL Management Studio or Visual Studio.  BTW, I'm using SQL Server 2008 R2 Express Edition and Visual Studio 2010 Professionnal Edition.
  First I started by connecting "AdventureWorks2008R2_Data.mdf" and "AdventureWorksDW2008R2_Data.mdf" to SQL Server Management Studio.  First trial failed but, right after deleting the log files, it succeeded.
  Now, in order to complete some tests/book exercises, I tried to connect those same databases to Visual Studio 2010.  First trial failed, but then, again after deleting the log files, it succeeded.
  The funny part is when I then opened SQL Server Management Studio, I just couldn't connect to those same databases again.  The database names are still listed but I just can't access them.  ...

Go to the complete details ...