If you develop applications in SQL Azure, you may end up in a situation where your code needs to know if it is operating in the root database or in a Federation Member, or if it is connected to a regular user database. Two ways can be used to make this determination: using system tables, or using the USE FEDERATION command. Using System Tables This approach is the easiest to implement since it relies a SQL call only, without much logic in your application code. Assuming your code is currently connected ......